Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/sentinel1909/57-exercises

A repo documenting my journey to do 57 programming exercises in Rust
https://github.com/sentinel1909/57-exercises

Last synced: 6 days ago
JSON representation

A repo documenting my journey to do 57 programming exercises in Rust

Awesome Lists containing this project

README

        

# 57-exercises
A repo documenting my journey to do 57 programming exercises in Rust.

## Exercise 1: Saying Hello
### Problem Statement:
The "Hello, World" program is the first program you learn to write in many languages, but doesn't involve any input.
So create a program that prompts for your name and prints a greeting using your name.

### Example Output:
What is your name? Jeff
Hello, Jeff, nice to meet you!

### Constraint:
Keep the input, string concatenation, and output separate.

### Solution:
To run:

```
cd say-hello
cargo run
```

### Output:
When the program is run, it will pause after displaying the initial greeting to wait for the user to input their name.

```
What is your name? *name*
Hello, *name*, nice to meet you!
```