Types and Streams
Types and Structs
Types make things better...and sometimes harder...but still better >:(
Recap
C++: Basic Syntax + the STL
Basic syntax
- Semicolons at EOL - Primitive types (ints,
doubles etc) - Basic grammar rules
The STL
- Tons of general functionality
- Built in classes like maps, sets, vectors
- Accessed through the namespace std::
Standard C++: Basic Syntax + std library
The STL Basic syntax
- Tons of general functionality - Semicolons at EOL
- Built in classes like maps, sets, vectors - Primitive types (ints,
- Accessed through the namespace std:: doubles etc)
- Extremely powerful and well-maintained - Basic grammar rules
Namespaces
MANY things are in the std:: namespace e.g. std::cout, std::cin, std::lower_bound
CS 106B always uses the using namespace std;
declaration, which automatically adds std:: for you We won't (most of the time)
it's not good style!
Today
- Types - Intro to structs - Sneak peek at streams!
C++ Fundamental Types
int val = 5; //32 bits char ch = 'F'; //8 bits (usually) float decimalVal1 = 5.0; //32 bits (usually) double decimalVal2 = 5.0; //64 bits (usually) bool bVal = true; //1 bit
C++ Fundamental Types++
#include int val = 5; //32 bits char ch = 'F'; //8 bits (usually) float decimalVal1 = 5.0; //32 bits (usually) double decimalVal2 = 5.0; //64 bits (usually) bool bVal = true; //1 bit std::string str = "Frankie";
................
................
In order to avoid copyright disputes, this page is only a partial summary.
To fulfill the demand for quickly locating and searching documents.
It is intelligent file search solution for home and business.
Related download
- python university of washington
- cs303e elements of computers and programming more
- introduction to python
- reading headers and calling functions donald bren school
- types and streams
- strings ncert
- types in python
- introduction to the python language wellesley college
- kendriya vidyalaya panchgram
- functions and abstraction
Related searches
- engine types and classification
- car engine types and classification
- different engine types and sizes
- enneagram types and wings
- expository writing types and examples
- fire engine types and classification
- essay introduction types and examples
- small business types and categories
- understanding blood types and compatibility
- coffee drink types and descriptions
- file types and extensions
- personality types and jobs