Font size
WorksheetsLearn to code 2 review
Total questions: 26
Worksheet time: 13mins
How would you name a variable
Var = Name
Let = Name
Submit
An assortment of items in a given code is a ___________.
index
array
variable
parameter
The number that represents the relative place of an item/Character is called an ___________.
index
array
variable
parameter
What is a parameter?
An integer which you need to set a relative position
A Assortment of items in a given code
A variable
Extra information in a code that is technology transferred through a function.
________________ is the act of creating a new instance of a type, which includes setting initial values for any properties of the type.
Type
Initialization
Boolean
Parameter
A _______________ is a named code that contains data on how the computer is supposed to react to the code.
parameter
boolean
variable
type
Is this the correct way to name a gem counter?
let GemCounter = TotalGems
Var gemCounter = 0
How would you add on in a variable (gemCounter)
gemCounter = gemCounter+1
Reeeeeee
SwitchCounter=switchCounter+1
How would initialize expert
If expert
While expert
Let expert=Expert()
expert.
Why is the key variable used?
To make life easier
To make our code tidy.
To add on sand make coding messier
_____________ is a named grouping of properties (the features) and methods (the behaviors) of a kind of data.
Type
Initialization
Boolean
Parameter
What is a type similar to.
Blueprint
Graphic
Jersey
Highway.
What do methods tell you in types.
The name of the property
The behavior of the code.
How variables are named.
How would you correctly write a method.
.MvofORwardx
.moveForward()
.MoveForward
Var moveForward = 0
How can you draw a comparison to portals and characters
Portals are type sort of like a character for example portals would be the type and green portal would be the instance and character would be the type and expert would be the instance
There the same
I don't know
jdnwbkhefifgdhiygwert4ehwrgsyefwhygvewkfgygefwjygfewhkefwghikefhf3kufeghueghgkergbkfeighufewgefwigfeiuyefwghyefghfeyfeghykefhbgfewykgfeyfewgbfewiqfhiouefqgvefwhiohjfekewf
Does a declaration statement come before or after the equal sign?
A let statemnet
var = gemCounter
Before
Let expert = Expert()
After
How would you write the correct parameter for moving a certain distance.
move(distance : 6) {
}
func move {
6 times
}
While move: 6
moveForward()
moveForward()
moveForward()
moveForward()
moveForward()
moveForward()
Which is the correct way to solve the level where you have to put a character on each block and then world is a straight line.
var rows [0,1,2,3,4,5,6]
place Characters (at :rows)
var rows [0,1,2,3,4,5,6]
place Expert (at :rows)
var rows [0,1,2,3,4,5,6]
place Blue (at :rows)
At what number to variables usually begin at
49
59
69
0
39
How would you activate a green portal?
greenPortal.isActive=false
greenPortal.isActive=true
purplePortal.isActive=false
greenPortal.isActive=true
How would you place a block facing South?
world.place (Block(), atColum:3, row:3)
world.place (Block(), facing south, atColum:3, row:3)
How would you remove a block?
world.place
world.place(sea append.)
world.removeBlock(at: coordinate)
what is the vague term for an unnamed coordinate
Cooordinate
Coordinates
Coordinate
coordinate
Which of the characters can jump
Expert
Blue
Byte
Piper
What are the three ways to write an array.
append.
append
world.place
world.remove
What is most efficient way to move forward 3 times
for I in 1... 3{
moveForward()
}
moveForward()
moveForward()
moveForward()
moveForward()
moveForward()
moveForward()
move (distance : 6)
