Online Test for Python

  1. Which of the following is NOT an area where Python is commonly used?
    Web development (server-side)
    Software development
    Mathematics
    Graphic design

  1. In which year was the Python programming language released?
    1995
    1991
    2000
    2005


  1. An “immutable” object is an object that can be changed after it is created.
    True
    False

  1. Which of the following operating systems does Python run on?
    Mac OS X only
    Mac OS X, Windows only
    Mac OS X, Windows, Linux only
    Mac OS X, Windows, Linux, and Unix only

  1. When execute Python program, Python first compiles source code(file statement) into a format known as pseudo code.
    True
    False

  1. What is the purpose of the "if" statement in Python?
    To create a loop
    To declare a variable
    To define a function
    To conditionally execute code


  1. Which of the following is a correct statement about Python programs?
    Python programs are composed of functions, loops, and objects.
    Python programs consist of variables, arrays, and objects.
    Python programs are divided into modules, statements, expressions, and objects.
    Python programs are made up of classes, methods, and expressions.

  1. Which of the following core types in Python is considered immutable?
    Lists
    Dictionaries
    Strings
    Sets

  1. What is the extension of the Python byte code file?
    .py
    pyc
    .pyd
    None of the above

  1. Which of the following core types in Python is considered mutable?
    Numbers
    Strings
    Tuples
    Lists

Post Your Question
Social Sharing
Search