Lecture 3 Flashcards
(3 cards)
0
Q
Data Types:
- What are data type’s?
- Why use data type’s?
- How to use data type’s?
A
- Data type’s specifies what type of info is stored by the variables
- So the program knows how much memory to allocate and how to interpret the allocated memory
- To declare:
~ to declare an integer number: int __;
~ to declare a character: char __;
~ to declare a decimal number: float __;
~ to declare a decimal number w/ high precision: double __;
1
Q
Variable:
- What are variables?
- Why use variables?
- How to use variables?
A
- Holds information that can be changed
- Programs w/ info that’s predetermined is not very useful
- Declare variables, initialize variables, & set, change, or display variables
2
Q
Conversion Specifiers:
~ is the part of the format specifier that determines the basic formatting of the value that is to be printed.
A
(Work more on this, ex. Like %c)