πŸ“Š Problem Solving and Python Programming
Q. Terminals are represented by diagonals in a flowchart.
  • (A) true
  • (B) false
  • (C) ---
  • (D) ---
πŸ’¬ Discuss
βœ… Correct Answer: (B) false

Explanation: the statement is false. terminals are represented by rounded rectangles. they indicate the starting or ending point in a flowchart.

πŸ“Š Problem Solving and Python Programming
Q. The operation represented by parallelograms.
  • (A) input/output
  • (B) assignment
  • (C) comparison
  • (D) conditions
πŸ’¬ Discuss
βœ… Correct Answer: (A) input/output

Explanation: the input/output operations are represented by parallelograms. they generally are used to display messages during input and output part of a program.

πŸ“Š Problem Solving and Python Programming
Q. The action performed by a structure must eventually cause the loop to terminate.
  • (A) sequence
  • (B) case
  • (C) repetition
  • (D) process
πŸ’¬ Discuss
βœ… Correct Answer: (C) repetition

Explanation: the action performed by a repetition structure must eventually cause the loop to terminate. otherwise, an infinite loop is created.

πŸ“Š Problem Solving and Python Programming
Q. The following symbol denotes:
  • (A) module
  • (B) terminal
  • (C) process
  • (D) i/o operation
πŸ’¬ Discuss
βœ… Correct Answer: (A) module

Explanation: this symbol is that of a module. the terminal is denoted by a rounded rectangle. i/o operation by a parallelogram and process by a rectangle.

πŸ“Š Problem Solving and Python Programming
Q. Which one of the following has the highest precedence in the expression?
  • (A) exponential
  • (B) addition
  • (C) multiplication
  • (D) parentheses
πŸ’¬ Discuss
βœ… Correct Answer: (D) parentheses

Explanation: just remember: pemdas, that is, parenthesis, exponentiation, division, multiplication, addition, subtraction. note that the precedence order of division and multiplication is the same. likewise, the order of addition and subtraction is also the same.

πŸ“Š Problem Solving and Python Programming
Q. Given a function that does not return any value, What value is thrown by default when executed in shell.
  • (A) int
  • (B) bool
  • (C) void
  • (D) none
πŸ’¬ Discuss
βœ… Correct Answer: (D) none

Explanation: python shell throws a nonetype object back.

πŸ“Š Problem Solving and Python Programming
Q. Which of the following will run without errors?
  • (A) round(45.8)
  • (B) round(6352.898,2,5)
  • (C) round()
  • (D) round(7463.123,2,1)
πŸ’¬ Discuss
βœ… Correct Answer: (A) round(45.8)

Explanation: execute help(round) in the shell to get details of the parameters that are passed into the round function.

πŸ“Š Problem Solving and Python Programming
Q. What is the return type of function id?
  • (A) int
  • (B) float
  • (C) bool
  • (D) dict
πŸ’¬ Discuss
βœ… Correct Answer: (A) int

Explanation: execute help(id) to find out details in python shell.id returns a integer value that is unique.

Jump to