Computer Flashcards
1
Q
Computer 9 (Text)
A
print(“Computer 9”);
2
Q
5 (Value)
A
print(5);
3
Q
5 (Text)
A
print(“5”);
4
Q
Escape sequence; Newline
A
“\n”
5
Q
Computer 9 (A new line after)
A
print(“Computer 9 \n”);
6
Q
The three data types
A
Text, integer, float
7
Q
thing (variable, text data type)
A
thing = “ “
8
Q
thing (variable, integer or float data type)
A
thing = 0
9
Q
Show “name (variable, text data type)” = “input” (Use the words: INPUT YOUR NAME: )
A
name = input(“INPUT YOUR NAME: “);
10
Q
Show “num (variable, integer data type)” = “input” (Use the words: INPUT NUMBER: )
A
num = int(input(“INPUT NUMBER: “));
11
Q
Show “num (variable, float data type)” = “input” (Use the words: INPUT NUMBER: )
A
num = float(input(“INPUT NUMBER: “));
12
Q
Addition
A
+
13
Q
Subtraction
A
-
14
Q
Multiplication
A
*
15
Q
Division
A
/