Q1. Which of the following is NOT a characteristic of a good algorithm?
(a) Precision
(b) Finiteness
(c) Infinite steps
(d) Input and Output
Q2. In a flowchart, the parallelogram symbol is used to represent:
(a) Start/End
(b) Process
(c) Decision
(d) Input/Output
Q3. Assertion (A): An algorithm must always stop after a finite number of steps.
Reason (R): Finiteness is one of the characteristics of a good algorithm.
(a) Both A and R are true and R is the correct explanation of A.
(b) Both A and R are true but R is not the correct explanation of A.
(c) A is true but R is false.
(d) A is false but R is true.
Q4. The process of identifying a problem, developing an algorithm and implementing it as a program is called:
(a) Decomposition
(b) Problem Solving
(c) Debugging
(d) Testing
Q5. Assertion (A): Selection construct is used when an algorithm has to choose between two alternatives based on a condition.
Reason (R): In selection, the flow of control depends on the outcome (true/false) of a condition.
(a) Both A and R are true and R is the correct explanation of A.
(b) Both A and R are true but R is not the correct explanation of A.
(c) A is true but R is false.
(d) A is false but R is true.
Q6. Which construct is used when a set of statements needs to be executed repeatedly?
(a) Sequence
(b) Selection
(c) Repetition
(d) Decomposition
Q7. The method of running an algorithm manually with sample inputs to check correctness is called:
(a) Coding
(b) Dry run
(c) Debugging
(d) Maintenance
Q8. In pseudocode, which keyword is used to take input from the user?
(a) PRINT
(b) COMPUTE
(c) INPUT
(d) INCREMENT
Q9. GIGO stands for:
(a) Good Input Good Output
(b) Garbage In Garbage Out
(c) Get Input Get Output
(d) General Input General Output
Q10. Breaking a complex problem into smaller, manageable sub-problems is known as:
(a) Algorithm
(b) Decomposition
(c) Verification
(d) Flow of Control
Q11. Define an algorithm. State any two characteristics of a good algorithm.
Q12. Differentiate between flowchart and pseudocode (any two points).
Q13. What is the purpose of the decision symbol in a flowchart? Give one example of its use.
Q14. Write the pseudocode to input two numbers and print their sum.
Q15. What is meant by flow of control? Name the three types of flow of control discussed in the chapter.
Q16. Why is verification of an algorithm important?
Q17. Draw a flowchart to find the square of a number. Also write the corresponding pseudocode.
Q18. Write pseudocode to check whether a number entered by the user is even or odd. Identify the error in the following pseudocode and correct it:
INPUT num
IF num MOD 2 = 0
PRINT "Even"
PRINT "Odd"
Q19. Explain the difference between sequence and selection with the help of an example from daily life.
Q20. The following pseudocode is written to calculate the average of 5 numbers. Identify the error(s) and rewrite the correct pseudocode.
SET count = 0, sum = 0
WHILE count <= 5
INPUT num
sum = sum + num
PRINT sum/5
Q21. What is decomposition? Explain with reference to the railway reservation system mentioned in the chapter.
Q22. Write a complete pseudocode to accept numbers from the user until the user enters 0 and then calculate and print their average. Also draw the corresponding flowchart.
Q23. Explain the process of verifying an algorithm using dry run with the help of an example of adding two time values given in hours and minutes. Show the necessary correction in the algorithm when minutes sum to 60 or more.
Q24. Compare any two algorithms to check whether a given number is prime or not on the basis of time complexity and space complexity. Which one would you prefer and why?
Q25. A school wants to develop a simple program to categorise students as Child (<13), Teenager (≥13 and <20) or Adult (≥20) based on age.
(a) Identify the input, process and output required.
(b) Write the pseudocode using appropriate selection construct.
(c) Draw a flowchart for the same.
(d) Which flow of control construct is being used here? Why?
Q26. A student is asked to write an algorithm to calculate the area and perimeter of a rectangle.
(a) List the steps required in the algorithm.
(b) Write the pseudocode.
(c) Draw the flowchart.
(d) How will you verify that the algorithm is correct?
Q1. (c)
Q2. (d)
Q3. (a)
Q4. (b)
Q5. (a)
Q6. (c)
Q7. (b)
Q8. (c)
Q9. (b)
Q10. (b)
Q11. An algorithm is a finite sequence of well-defined steps that, when followed, solves a problem. Characteristics: Precision, Finiteness (1 mark each).
Q12. Flowchart is a visual/pictorial representation using symbols; pseudocode is a textual representation using English-like statements (1 mark each).
Q13. Decision symbol (diamond) is used for checking a condition and branching (1 mark). Example: checking if a number is even or odd (1 mark).
INPUT num1
INPUT num2
COMPUTE Result = num1 + num2
PRINT Result
(2 marks)
Q15. Flow of control shows the order in which statements are executed. Types: Sequence, Selection, Repetition (1+1 marks).
Q16. Verification ensures the algorithm produces correct output for all inputs and helps identify missing or incorrect steps (2 marks).
Q17. Flowchart: Start → Input num → square = num * num → Print square → End. Pseudocode:
INPUT num
COMPUTE square = num * num
PRINT square
(3 marks)
Q18. Error: Missing ELSE. Corrected:
INPUT num
IF num MOD 2 == 0 THEN
PRINT "Even"
ELSE
PRINT "Odd"
END IF
(3 marks)
Q19. Sequence: steps executed one after another (e.g., getting ready for school). Selection: decision-based branching (e.g., if age ≥ 18, eligible to vote) (3 marks).
Q20. Errors: loop condition should be < 5, increment of count missing, average calculation inside loop. Corrected pseudocode given with proper indentation (3 marks).
Q21. Decomposition is breaking a complex problem into smaller sub-problems. Railway reservation system is decomposed into train info, reservation, billing, food service, etc. (3 marks).
Q22. Correct pseudocode and flowchart with WHILE loop until 0 is entered, accumulating sum and count, then computing average (5 marks).
Q23. Dry-run example with T1 = 4 hrs 50 min, T2 = 2 hrs 20 min showing mm_total ≥ 60 case; correction by adding 1 to hours and subtracting 60 from minutes (5 marks).
Q24. Comparison of prime-checking algorithms on time (number of divisions) and space (storage of primes); preference for square-root method due to lower time complexity (5 marks).
Q25. (a) Input: age; Process: check ranges; Output: category (1 mark).
(b) Correct if-elseif-else pseudocode (1 mark).
(c) Flowchart with decision diamonds (1 mark).
(d) Selection construct, because decision depends on condition (1 mark).
Q26. (a) Input length & breadth, compute area & perimeter, print (1 mark).
(b) Correct pseudocode (1 mark).
(c) Flowchart (1 mark).
(d) Dry run with sample values (1 mark).
All questions are answerable from the NCERT chapter text. Reviewed by GFIS faculty.