SmartStart_Curriculum_3.1_en
Smart Start Curriculum. Area 3: Algorithmic thinking 73 / 76 Exercise 5: One Problem, Two Coding Solutions Topic: Comparing and evaluating algorithmic solutions Objective: To understand that the same problem can be solved using different algorithms and to evaluate solutions according to clarity, efficiency, and ease of modification. Format: Pair or small-group comparative activity. Instructions: Consider the task: Create instructions that display the numbers 1 to 5. Solution A: print(1) print(2) print(3) print(4) print(5) Solution B: for number in range(1, 6): print(number) Compare the two solutions. Discuss: • Do both produce the same output? • What algorithmic structure is used in Solution B? • Which solution is easier for a beginner to understand? • Which solution would be easier to modify if the program needed to display numbers 1 to 100? • Is the shorter solution always the better solution? • What criteria should be used to decide whether an algorithm is “better”? Next, design two different solutions to another simple problem, such as repeating a message five times or giving feedback based on a student's score. Deliverable: A comparison of the two solutions using at least three criteria, such as clarity, efficiency, scalability, and ease of modification , followed by a justified choice of the preferred solution.
Made with FlippingBook
RkJQdWJsaXNoZXIy MjQzMTQ4