Commit c98c0bdf authored by Erik Strand's avatar Erik Strand
Browse files

Update READMEs

parent 548c36cc
......@@ -8,8 +8,10 @@ your toolchain is installed correctly, this will build two programs: `hello_worl
demo@linux:01_hello_world$ make
gcc -Wall -O3 -o hello_world_c hello_world.c
g++ -Wall -O3 -o hello_world_cpp hello_world.cpp
demo@linux:01_hello_world$ ./hello_world_c
hello, world, I'm C
demo@linux:01_hello_world$ ./hello_world_cpp
hello, world, I'm C++
```
......
# Control Structures
These examples demonstrate loops and functions.
```
demo@linux:02_control_structures$ make
gcc -Wall -O3 -o loops loops.c
gcc -Wall -O3 -o functions functions.c
demo@linux:02_control_structures$ ./loops
while loop: 0
while loop: 1
while loop: 2
while loop: 3
while loop: 4
for loop: 0
for loop: 1
for loop: 2
for loop: 3
for loop: 4
another while loop: 0
another while loop: 1
another while loop: 2
leaving the while loop
1 is odd
3 is odd
i is 42
demo@linux:02_control_structures$ ./functions
two is even
three is odd
four isn't prime
5! = 120
6 choose 4 = 15
```
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment