stud
bud
Sign up
Log in
Home
Library
Explore
SAT
More
Swift Playgrounds, commands - parameters 2 Flashcards | StudBud
Explore
/
Swift Playgrounds, commands - parameters 2
Swift Playgrounds, commands - parameters 2
26 terms
·
StudBud Administration
·
44 plays
student review of Swift programming using Playgrounds, commands - parameters
Flashcards
26 cards
F
Practice quiz
P
Host live
L
Questions
26
Answers
1
What is boolean?
A single value of either TRUE or FALSE
Statements that only run under certain conditions.
2
What does Byte collect in Swift Playgrounds?
Rubies
Switches
Gems
Diamonds
3
What code is missing to solve this puzzle?
collectGem()
turnLeft()
moveForward()
toggleSwitch()
4
what is a "variable" in coding?
A placeholder for a piece of information that can change
a function
a special term for "r,g,b" color
a mathematical operator
5
How many moveForward() commands are required to solve this puzzle?
3
none
4
5
6
What is a for loop used for?
tell Byte what to do 1 time
check conditions for true or false value
repeat code a set number of times
repeat code 4 times
7
How many times should this for loop repeat?
5
1
none
2
8
What is the character's name in Playgrounds?
Blu
Swift
Byte
Bit
9
What is an algorithm
A series of instructions on how to accomplish a task
Finding bugs in code
A rhythm used to sing a song about computers
The person who writes code
10
Which line of code contains a bug?
5
4
3
2
11
What is the difference between LET and VAR in Swift?
LET is for variables, VAR is constants
LET is for constants, VAR is for variables
Nothing... they are both the same thing.
LET means concatenation, VAR means variation
12
What is an integer.
An even number
A fraction
A whole number
An odd number
13
What code is missing in the function to solve this puzzle?
moveForward()
toggleSwitch()
turnRight()
collectGem()
14
What is syntax?
an error on my calculator
A computer program
syntax is the rules for the use of symbols in programming
it's like the rules for punctuation in writing.
15
How many turnLeft() commands are required to make Byte turn right?
3
1
2
4
16
Used for making notes and tell you what your programming does
Comment
Command
Constant
Variable
17
What does ITERATE mean?
Repeat
Idea
Test
Presentation
18
What does the orange dot mean?
a word is misspelled
which line the program is currently at when running the code
there is a bug in the code and it cannot compile
the line of code your are currently writing
19
the moveForward() command tells Byte to move forward how many spaces?
3
4
1
2
20
Will this code solve the puzzle?
No
Yes
21
In programming, what is a function?
A set of commands given a name
A set of directions in correct sequence
program created by a code
A bug that is causing a code not to work
22
What is the name of the parameter?
name
greet
String
func
23
What are conditionals?
while statements
if/else statements
for statements
&&, ||, ! symbols
24
What is a computer bug?
an error in the code
an insect
proper sequence of code
a command in the code
25
Which of these is Camel Case?
This_Is_A_Variable
thisIsAVariable
this_Is_A_Variable
ThisIsAVariable
26
Can an if {} statement be placed inside another if {} statement?
No
Yes
Maybe