stud
bud
Sign up
Log in
Home
Library
Explore
SAT
More
Y9 Coding Flashcards | StudBud
Explore
/
Y9 Coding
Y9 Coding
30 terms
·
StudBud Administration
·
131 plays
Imported from external platform
Flashcards
30 cards
F
Practice quiz
P
Host live
L
Questions
30
Answers
1
What is the name of the programming language we are learning to code in?
Python
Shell
Replit
2
What always happens when we create a variable?
The code saves a value to the computer's memory
The code gets the user to enter their data
The code gets the computer to make a calculation
3
What is the meaning of == ?
equals
assign to
not equals
4
Which symbol is used when we want to write a comment next to our code?
#
//
%
5
What is indentation?
A way to make the code easier for the user to view
A way to make the Python code look more tidy
A way to tell the computer that some lines of code belong together
6
What is the outcome of the following code?
Yellow
Red
x
7
Pick the line without any mistakes in it.
print("Hello World, my name is", name)
print("Hello World, my name is" name)
print("Hello World, my name is", Name)
8
Which of these snippets of code will output the string Hello World
print"Hello World"
print("Hello World")
print(Hello World)
9
Which of these statements about comments in Python is
FALSE
?
Every line of code has to have a comment explaining what it does
Comments enable us to leave notes to ourselves and others
Comments can be written above, below and on the right hand side of our code
10
What is a variable?
It is a way of displaying a message in the Shell
It is a number that keeps on changing
It is a value saved to the computer's memory
11
What is the output of the below code?
nay
yay
error
12
Which of these variables is correctly written?
myName = James
My_Name = "James"
My name = James
13
Which of the variables below is a string?
item = 10
item = "Bob"
item = 3.15
14
Which of these statement about integers is
FALSE
?
Integers are whole numbers (1, 2, 3, 4, 5.. etc)
Integers can be used in mathematical operations
Integers are written with speechmarks around them
15
What do we mean by the term
DEBUGGING
?
Making the code easier to read and understand
Making the code more user friendly
Removing errors from the code to make it run correctly
16
Which of the below functions is used for casting?
int()
input()
print()
17
Which outcome is correct for the below snippet of code?
Error
That’s £8 in total
That’s £ Pizza+Chips+Soda in total
18
Which of the below statements is
TRUE
?
neither are strings, they are both numbers
y is a string and x is not a string
x is a string and y is not a string
19
What is the final outcome of the below code?
28
14
1414
20
What has to be added to the below code to make it work?
Nothing
Quotation marks around the numbers
Add int() to each item price
21
Which of the below IF statements is
CORRECT
?
if age == 18:
if age = 18:
if age === 18:
22
Which of the below statements about the input() function is
FALSE
?
The input() function enables us to create an interactive program
The input() function gets the user to add data to our code
The input() function is used to put data into Replit
23
Which word is
NOT
used in IF statements?
ELSE
ELIF
THEN
24
Which of the below statements about selection is
TRUE
?
It enables our code to have more than one outcome
It enables the user to enter any number they want
It enables the computer to choose which data to save into its memory
25
Which key on the keyboard should be used to make an indentation?
Space
Tab
Underscore
26
What does the int() function
NOT
do?
It integrates numbers with each other
It turns a value into a whole number
It enables us to use a number for calculation
27
What is the outcome of this code?
Hello, Anne
Hello Anne
Error
28
What does = mean when creating a variable
Equals
Assign to
Matches
29
Which of these variables is correctly written?
myNumber = 10
My_Number = 1 0
My number = 10
30
Which mathematical operation uses one * symbol (asterisk) in Python?
Division
Multiplication
Exponentiation