Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

11. What is the value of C after these lines of code run? a = 40 b = 55 c = 150 if a

11.   What is the value of C after these lines of code run?

a = 40

b = 55

c = 150

if a <= 50:

    b = 15

if b < 30:

    c = 100

else:

    c = 200

 

12.   How many times will print be called by this code?

n = 3

while n < 10:

    print( n )

    n += 1

 

13.   Does range() have to take a parameter?

 

14.   create a for loop that counts down from 15 to 10 and includes both 15 and 10

 

 

What is the output after this code runs:

x = 0

y = 0

while x < 5:

  for k in range( 1, 4 ):

        y = y + k

  x = x + 1

  print( 'x:', x, 'y:', y)

Step by Step Solution

3.25 Rating (143 Votes )

There are 3 Steps involved in it

Step: 1

1 What is the val... blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Income Tax Fundamentals 2013

Authors: Gerald E. Whittenburg, Martha Altus Buller, Steven L Gill

31st Edition

1111972516, 978-1285586618, 1285586611, 978-1285613109, 978-1111972516

More Books

Students also viewed these Programming questions