Question: a. Can a for Loop be written in a way that it runs forever ? Can a while Loop do that ? Justify your answer

a. Can a for Loop be written in a way that it runs forever ? Can a while Loop do that ? Justify your answer either by writing code examples or explaining. b. Could you assign a variable using the following code : not = 3 . Explain what is the reason for your answer.

c. Which of these statements are correct or not: Creating and assigning a new variable, for example number = 2, returns True. Negating a False Expression returns False, for example not (3<1). Combination of a False and False Expression returns True

. d. Describe what is Indentation when writing code that contains Conditionals (if, elif, else). Is Indentation a requirement in the code and why ? Can we have multiple levels (nested) of Indentation, and in which case multiple levels on Indentation would appear.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!