Practice questions
- You want to store the number of apples in a shop. What is the best variable name and data type?
A. numApples, integer b. apples, text c. numApples, string d. isApples, boolean
Answer = A
- You are storing true or false in a variable that asks if the classroom is cold. What is the best variable name and data type?
A. weather, integer b. weather, boolean c. isCold, boolean d. cold, string
Answer = c
- How do you store the ID numbers for the students in the classroom? Choose the best variable name and data type:
A. IDnumber, string b. whatID, integer c. IDnumberofthestudentsintheclassroom, boolean d. IDnumberofthestudentsintheclassroom, integer
Answer = A
- Is itisRainingtodayinsandiego a better option than isRaining?
A. Yes b. No
Answer = no
- Which of the following types of data is best for a true or false question?
A. Boolean b. String c. Float d. All of the above
Answer = A
- What is the difference between an integer and string of numbers?
A. An integer is just a set data type while a string of numbers can be changed with addition and subtraction b. An integer can be letters and numbers while a string is just numbers c. An integer is just numbers while a string is just words d. An integer can be changed with addition and subtraction and a string is a set number or string of letters.
Answer = D
My practice questions
- You want to store the number of cheeseburgers in a resturant. What is the best variable name and data type?
A. numcheeseburgers, integer b. cheeseburgers, text c. numcheeseburgers, string d. ischeeseburgers, boolean
Answer = ?
- How do you store the amount of food the students eat in the classroom? Choose the best variable name and data type:
A. IDfood, string b. whatfood, integer c. amountoffood, boolean d. amounoffood, integer
Answer = ?
- Is eatingallthefoodintheworld a better option than eatingfood?
A. yes b. No
Answer = ?