Richard's C++ Ch 4, 5

================
C++ is case sensitive
================


Ch 4. Making Decisions

eg021_if_else.cpp, if ... else ... syntax

Relational Operators:
> Greater than
< Less than
>= Greater than or equal to
<= Less than or equal to
== Equal to
!= Not equal to

Logical Operators:
&& AND
|| OR
! NOT

eg022_if_elseif.cpp, if ... else if ... and switch syntax

eg023_morelogic.cpp, more if

 

Ch 5. Loops and Files

eg024_while.cpp, while loop, this one does not have error checking, may crash if enter something wrong

eg025_for.cpp, for loop

eg026_post_pre.cpp, Postfix and Prefix modes for ++ and -- operators

eg027_do_while.cpp, do while loop for a simple menu

eg028_nested_for.cpp, nested for loop (2D and 3D)

eg029_while.cpp, while loop, sentinel (marks end of loop), accumulator for total value

eg030_writereadfile.cpp, write data to a file, reading data from file

eg031_filename.cpp, allow user to specify a file name