Game Preview

CPSC 110 Exam 2 Review

  •  English    6     Public
    Python
  •   Study   Slideshow
  • Suppose X = "100" and Y="105". What would be stored as result after the statement result = X + Y
    100105
  •  10
  • The problem description says "define a function that...". What Python reserved word should definitely be in your solution?
    def (return is also acceptable)
  •  15
  • The problem description says "keep repeating until the user enters an "X". What reserved word should definitely be in the solution?
    while
  •  15
  • The problem statement says "call a function in the standard Python library". Does your solution need to include an import statement?
    no
  •  10
  • The problem statement says "call a function in a non-standard Python library." What reserved word has to be in the solution?
    import
  •  10
  • To call a function, you need to know 4 pieces of information. Name any 2.
    library/location of the function, function name, expected arguments, returns a value or not
  •  15