Smaller Differences
- C++ notation can be more terse and less verbose than Racket.
- C++ arithmetic expressions use infix rather than prefix
form.
- The minus sign "-" cannot be used to hyphenate names, as in
my-list, since it will be taken as a subtraction. Instead, C++
would use my_list or myList.
- C++ structures programs using curly braces { ... }, which can be
nested.
- C++ procedure calls have the form procedure( ... )
compared to Racket's (procedure ... )
- C++ procedures are called functions or methods.
- C++ expressions that are statements must be terminated by a
semicolon ";"
- One of the procedures (methods) in a C++ program must be named
main; the C++ system launches a program by first running
main.