1. Home
  2. Explore
  3. Computer Science
  4. Python Variables Basics

Study methods

Flashcards
Quiz
Fill in the blanks
Written test
Lesson
Notes
Podcast
Content

Python Variables Basics

  • 35Unfamiliar
  • 0Learning
  • 0Familiar
  • 0Mastered
Topic: Python Overview
Python is considered one of the most
programming languages.

35 questions

  1. 1
    Python is considered one of the most
    _____
    programming languages.
    Hint

    Think about how widely it is used in industry and academia.

    Answer

    popular

  2. 2
    Python is used at both small companies and larger companies, including
    _____
    .
    Hint

    A major tech company that uses Python.

    Answer

    Google

  3. 3
    One advantage of Python is its fairly simple
    _____
    .
    Hint

    The set of rules that defines the structure of the language.

    Answer

    syntax

  4. 4
    Python is used for websites'
    _____
    code, which runs on the server.
    Hint

    The part of a web application that is not visible to the user.

    Answer

    back-end

  5. 5
    Python is popular for data analysis and
    _____
    research purposes.
    Hint

    Related to experiments and studies in science.

    Answer

    scientific

  6. 6
    IDE stands for Integrated Development
    _____
    .
    Hint

    The last word of the acronym IDE.

    Answer

    Environment

  7. 7
    An IDE includes a text editor, the ability to run a program, and a
    _____
    for debugging.
    Hint

    A tool that helps find and fix bugs.

    Answer

    debugger

  8. 8
    The recommended IDE for this series is PyCharm
    _____
    Edition.
    Hint

    The free version of PyCharm.

    Answer

    Community

  9. 9
    Jupyter Notebook is an environment for writing and testing your program
    _____
    .
    Hint

    Opposite of slowly; it allows rapid development.

    Answer

    quickly

  10. 10
    Jupyter Notebook is popular with the scientific community and for
    _____
    purposes.
    Hint

    Examining and interpreting data.

    Answer

    data analysis

  11. 11
    Jupyter Notebook has two components: a server (command line) and a
    _____
    (browser window).
    Hint

    The part you interact with visually.

    Answer

    user interface

  12. 12
    If you close the Jupyter Notebook server window, the notebook might stop
    _____
    .
    Hint

    What happens when the core component is shut down.

    Answer

    working

  13. 13
    Anaconda is a
    _____
    manager that allows you to install many programs at once.
    Hint

    A tool that handles software packages.

    Answer

    package

  14. 14
    When installing Anaconda, you should choose Python
    _____
    version.
    Hint

    The newer major version of Python.

    Answer

    3

  15. 15
    To launch Jupyter after installing Anaconda, you launch
    _____
    Navigator.
    Hint

    The application that comes with Anaconda to manage environments.

    Answer

    Anaconda

  16. 16
    In Jupyter Notebook, a new notebook is created by clicking New and then
    _____
    .
    Hint

    The kernel to use for Python code.

    Answer

    Python 3

  17. 17
    Notebook files have the extension
    _____
    .
    Hint

    The file extension for Jupyter notebooks.

    Answer

    .ipynb

  18. 18
    In Jupyter Notebook, each
    _____
    represents a set of code.
    Hint

    The building block of a notebook.

    Answer

    cell

  19. 19
    To execute code in a cell, you use the
    _____
    button at the top.
    Hint

    The action to execute the code.

    Answer

    run

  20. 20
    The print() function prints whatever is inside the
    _____
    .
    Hint

    The symbols that enclose function arguments.

    Answer

    parentheses

  21. 21
    A string in Python is usually enclosed by double quotes or
    _____
    quotes.
    Hint

    The other type of quotation mark.

    Answer

    single

  22. 22
    If you forget to close the parentheses when using print(), you will get an
    _____
    .
    Hint

    Something that indicates a problem in the code.

    Answer

    error

  23. 23
    You can print a
    _____
    instead of a string, for example print(3).
    Hint

    A numeric value without quotes.

    Answer

    number

  24. 24
    In the statement a = 1, the variable a is assigned the value
    _____
    .
    Hint

    The numeric value on the right side of the equals sign.

    Answer

    1

  25. 25
    A variable in Python is more accurately thought of as a
    _____
    that can refer to any value.
    Hint

    An item that labels something, not a container.

    Answer

    name tag

  26. 26
    Using print(a) without quotes around a prints the
    _____
    that a refers to.
    Hint

    What the variable represents.

    Answer

    value

  27. 27
    Two or more variables in Python can
    _____
    to the same value.
    Hint

    Another word for 'point to'.

    Answer

    refer

  28. 28
    Reassigning a variable changes what it
    _____
    to.
    Hint

    The relationship between variable and value.

    Answer

    refers

  29. 29
    A variable can be reassigned to a different
    _____
    of value, such as from number to string.
    Hint

    Category like integer or string.

    Answer

    type

  30. 30
    Trying to print a variable that does not exist results in a
    _____
    .
    Hint

    An error that occurs when a name is not defined.

    Answer

    NameError

  31. 31
    If a = 1 and f = a, then f refers to the value
    _____
    .
    Hint

    The same value a originally refers to.

    Answer

    1

  32. 32
    After a = 1; f = a; a = 2, the value of f remains
    _____
    .
    Hint

    f does not change when a is reassigned.

    Answer

    1

  33. 33
    The naive swap v1 = v2; v2 = v1 fails because both variables end up referring to the
    _____
    value.
    Hint

    Opposite of different.

    Answer

    same

  34. 34
    A proper way to swap two variables uses a
    _____
    variable to temporarily hold one value.
    Hint

    An extra variable used for storage during the swap.

    Answer

    temporary

  35. 35
    The correct swap pattern is: `temp = v1; v1 = v2; v2 =
    _____
    `.
    Hint

    The variable that holds the original first value.

    Answer

    temp

1 of 35
Question 1 of 35

Ask anything

We've read this whole study set, so questions about it get the best answers.

FlashcardsQuizFill in the blanksWritten testLessonNotesPodcastContent