Debugging and Clean Coding
Javascript Syntax
Programming Fundamentals
BONUS
100

We refer to this as "blanks", characters that represent space between other characters.

What is whitespace?

100

This is the keyword for creating a variable in JS.

(Bonus for double points: These are two other keywords for creating variables in JS)

What is "var"?

100

This is a placeholder for information that can change.

What is a variable?

100

These are the 4 essential components of ALL computers.

What are input, output, processing, and storage?

200

This is essential in writing clean code, as it allows programmers to easily see which code falls within the selection or iteration, and where it ends.

What is indentation?

200

This is the syntax for writing a while loop in JS.

(Bonus, for 100 points: this is how you write a for loop in JS)

What is the answer as fact checked by Ms. Dunlap and the class?

200

We end all programming statements with this in JS.

What is a semicolon?

200

This is the difference between roll and pitch.

(Bonus for 100 points: This is the difference between the yaw and the aforementioned rotation axes)

What is rotation about the transverse axis vs. the longitudinal axis?

https://www.liskeforensics.com/blog/title/vehicle-pitch-roll-and-yaw/id/249/

300

This is how you write comments in JS.

What are "//" and "/* */"?

300

These are the steps you should take when you're either unsure of:

a) how to write something in a specific programming language

b) whether something exists in the language, or

c) how to use and apply a built-in function.

What is "googling" it? 

What is reviewing documentation? 

What is referencing resource websites? (i.e. w3schools, geeksforgeeks, developer.mozilla.org, etc.)

300

These are the 4 programming problem solving steps.

(Bonus for 100 points: these are examples of how to apply each problem solving step)

What is Define, Prepare, Try, and Reflect?

300

This is a list of instructions to complete a task.

(Bonus for 100 points: expressions that evaluate to either true or false)

What is an algorithm?

Bonus: what is a conditional statement?

400

This is something we should check for if we notice an animation is not working. Typically, this is the root of the problem?

What is the fact that we're not using a draw loop? What is not incrementing your variable? What is not using variables for our drawings?

400

What is the syntax for writing an if statement in JS?

What is the following?

if (condition) {

//code that should happen if the condition is true

}

400

These are the debugging tips you can use when your code won't work.

(Fun fact: a lesson on debugging will provided as HW following this class)

What is commenting out lines of code until you find where your code breaks? What is checking for syntax errors?

What is println() or print()? What is console.log? What is exaggerating your output?

https://www.khanacademy.org/computing/computer-programming/programming/debugging-programs/a/more-debugging-tips

400

This is a list of at least 6 function commands we've learned during our computer graphics unit on KhanAcademy?

What are various shapes, the fill() command, strokeWeight(), draw function, custom functions, etc?

500

This is what the below code will output.

var x = 3;
var i = 0;
while (i < 3) {
  x += 1;
  i += 1;
}
println(x);

What is 6?

500

These are at least 5 of the comparison and logic operators in JavaScript. 

(Bonus for 200 points: These are the differences between "=", "==", and "===".)

What are the items on the list of Ms. Dunlap's screenshot?

(Bonus: What is an assignment operator, vs. an equality operator, vs. a strict equality operator?)

500

This is an example of how to write a nested if statement.

(Bonus for 100 points: providing at least 3 examples of conditional statements show up in real life programming)

What is a correct answer drawn on the board?

500

These are the names of all of the students in this class + one bonus fact about them.

What is the correct answer, based on fact checking from Ms. Dunlap and the class? :)

M
e
n
u