• 6 hours
  • Easy

Free online content available in this course.

course.header.alt.is_video

course.header.alt.is_certifying

Got it!

Last updated on 4/11/24

Manage Program Logic in Python

Evaluated skills

  • Manage program logic in Python
  • Question 1

    Which data type is used to run an if/else statement in Python?

    • Boolean

    • Integer

    • True/false statements

    • Float

    • Strings

  • Question 2

    Which of the following can be used to check multiple conditions?

    Careful, there are several correct answers.
    • else

    • and

    • while

    • or

    • not

  • Question 3

    Given the following list  global_cities = ["New York", "Paris", "London", "Shanghai"] , which of the following for loops will print each element in the list?

    • For city in global_cities:
          print(city)
      
    • for city in global_cities;
          print(city)
      
    • for city in global_cities:
          print(global_cities)
      
    • for city in global_cities:
          print(city)
      
    • for city in global_cities
          print(city)
      
Ever considered an OpenClassrooms diploma?
  • Up to 100% of your training program funded
  • Flexible start date
  • Career-focused projects
  • Individual mentoring
Find the training program and funding option that suits you best