Check out example codes for "c++ declare variable". It will help you in understanding the concepts better.

Code Example 1

std::string str = "text";	// stores a string
int    foo = 3;				// stores any integer
float  bar = 3.14;			// stores 32 bit number
double baz = 3.14159265;	// stores 64 bit number

Learn ReactJs, React Native from akashmittal.com