Computer Science > QUESTIONS & ANSWERS > Code HS 2 Questions and Answers with Certified Solutions (All)
Code HS 2 Questions and Answers with Certified Solutions Why are parameters useful? ✔✔They allow us to tailor functions to be used in multiple situations How many parameters can we use in each ... function? ✔✔As many as we need What is the default starting value of i in a for loop? ✔✔0 What will the values of i be at each iteration of the loop below? For i in range(3): ✔✔0, 1, 2 What will happen when the value of i reaches 5 in the loop below? for i in range(5): left(i) right(90) ✔✔Tracy will turn 90 degrees to the right Why do we use if statements? ✔✔To have Tracy make decisions based on conditional statements If we write an if statement and the condition is false, what does Tracy do? ✔✔Tracy skips the commands under the if statement How would we write an if statement where Tracy will put the pen down if a variable called count was positive? ✔✔if count > 0: pendown() Which comparison operator means 'is not equal to'? ✔✔!= If the following code was run, how far would Tracy move? ✔✔100 pixels [Show More]
Last updated: 2 years ago
Preview 1 out of 2 pages
Buy this document to get the full access instantly
Instant Download Access after purchase
Buy NowInstant download
We Accept:
Code HS Bundled Exams Questions and Answers with Complete Solutions
By Nutmegs 2 years ago
$25
18
Can't find what you want? Try our AI powered Search
Connected school, study & course
About the document
Uploaded On
Apr 13, 2023
Number of pages
2
Written in
All
This document has been written for:
Uploaded
Apr 13, 2023
Downloads
0
Views
110
Scholarfriends.com Online Platform by Browsegrades Inc. 651N South Broad St, Middletown DE. United States.
We're available through e-mail, Twitter, Facebook, and live chat.
FAQ
Questions? Leave a message!
Copyright © Scholarfriends · High quality services·