C++ Basics
Terms
undefined, object
copy deck
- "if" is followed by
- condition in () and then statements to be executed in {}, optionally an else may follow
- how best to include standard io library (for beginnners)
-
#include <iostream>
using namespace std; - For regular command line output cout should immediately be followed by (just supply the next token needed):
- <<
- For regular command line input cin should immediately be followed by (just supply the next token needed):
- >>
- token for an end of line in command line output using iostream
- endl
- glues together .o files to make an executable
- the linker
- creates object code (and can call the linker to create executables)
- the compiler (often called g++.exe)
- starting function for a command line based program (show prototype)
-
int main(int argc,char *argv[])
or
int main() - class used to do file output using iostream library
- ofstream
- set minimum width of next output to 5 within an output stream
- setw(5)