Practice Test #1
1. How many bits are in 2 bytes? select 2 8 16 64
2. A computer that uses vacuum tubes is newer than one that uses transistors. select True False
3. What do you call a base-16 numbering system? select binary octal decimal hexadecimal
4. What is the sum of 1 and 1 in binary? select 2 1 11 10
5. A byte can represent a decimal number between 0 and ? select 255 256 7 8
6. What kind of program is used to convert source code to executable code? select OS builder compiler programming language
7. What variable type would use the least memory to store a persons age? select short int float int double
8. What variable type would be best for storing the world's population? select string unsigned int double float
int Hello; cout << "Enter a value: "; cin >> Hello; //user enters "10" cout << "Hello";
int A, B; cout << "Enter a value: "; cin >> B; //user enters "5" cout << "Enter a value: "; cin >> A; //user enters "4" cout << A+B*A+B;
float X = 5.5, Y = 0; X++; Y++; X = X + Y * 2; cout << X;
short int Two = 1; short int Three = 2; short int Four = Two + Three; cout << Four % 2;
13. What's the largest number an unsigned short int variable be? select 255 0 4294967295 65535
14. What's the smallest number an unsigned int variable can be? select 0 -255 -32767 -65535
15. What variable type would be best for storing the value of Pi? select char unsigned int short int float
You got out of correct. Your Score: %