You are on page 1of 3

Computational Thinking

Module 1: Principles of Computational Thinking

Session 8: What is the data type?

Name:_________________________________________________ Id number: _____________

Part 1: For the following variable names, write correct if the name is correct.
if it is not a valid variable name write down incorrect and justify your answer.

● country correct

● bill_Total correct

● Total_9 correct

● Name correct

● 56total incorrect, can’t start with a number

● Result4 correct

● PriceTotalArticle67 correct

● #music incorrect, cant have a hashtag

● <operation>. Incorrect, Can’t have special characters apart from “_”

● conT correct

● #articles incorrect, cant have hashtag

● cont4 correct

● nameLastName correct
Part 2: Analyze and write down the data type of each example, if it does not
belong to any data type, write down the word error.

#Hello World true Boolean “False”

error Integer
32.4 float 11.00 float “34”

Error
Name error “Carlos5” “45.6 grams”

integer Error
false 175 integer 3.1416 float

boolean
“87-43-21” error Johny” error “78 error

conT error 43-23-12 error -89 error

Part 3: Write down the final value of each of the variables. If the value is not
correct, write the word error.
3.1.

variable1 = 8 3.2.
variable2 = 18.4
variable3 = 2.6 Nombre = “Johnny”
total = variable1 + 2.0 Apellido = “Smith”
total = variable 2 + variable3 Nombre = Nombre + Apellido

total = ___”10-21”___ Nombre = __”JohnnySmith”__

Rename this file to S8_A0XXXXXXX where XXXXXXX is your id number, and send it via
the assignment in Canvas.

You might also like