MSHS 2019 P2
Uploaded by IDKWHYBUTIAM · 3 November 2024
Preview
Class/ Index Number / Centre Number/ ‘O’ Level Index Number / Name MARIS STELLA HIGH SCHOOL PRELIMINARY EXAMINATION SECONDARY FOUR COMPUTING 7155/02 Paper 2 (Lab-based) 29 Aug 2019 2 hours 30 minutes Additional Materials: Electronic version of BANK.XLSX data file Electronic version of WEIGHT.PY file Electronic version of RIDE.PY file Insert Quick Reference Glossary READ THESE INSTRUCTIONS FIRST Answer all questions. All tasks must be done in the computer laboratory. You are not allowed to bring in or take out any pieces of work or materials on paper or electronic media or in any other form. Programs are to be written in Python. Save your work using the file name given in the question as and when necessary. The number of marks is given in brackets [ ] at the end of each question or part question. The total number of marks for this paper is 50. For Examiner’s Use This document consists of 6 printed pages. 50 Thumb drive No:
2 Task 1 Maybey Bank uses spreadsheet software to record its customers’ loan records. You are required to finish setting up the spreadsheet to record the details. Open the file BANK.XLSX. You will see the following data. Save the file as LOAN_<your name>_<class>_<index number> 1 For the cell range B5:B16, use an appropriate function to extract the first letter of the Customer Code to represent the Account Type. [1] 2 Use an appropriate function to search for the Number of Years in the Loan Plan Term Table given and use it to complete the Number of Years in Loan Plan column. [2] 3 Use an appropriate function to search for the Interest Rate per Annum in the Interest Rate Table given and use it to complete the Interest Rate per Year column. [2] 4 Enter a formula to calculate the total amount of money each customer will have to pay at the end of their loan plan period. This is based on the Number of Years in Loan Plan, Interest Rate per Year compounded monthly and Loan Amount. Use that value to complete the Total Amount of Pay column [3] 5 Use a conditional statement, to identify those customers who have taken a loan amount of more than $45000 and whose application method was online, and put YES in the Free $70 Cash-back column. Otherwise, put NO in the Free $70 Cash-back column. [2] Save and close your file. Task 2
3 The following program accepts the weight in kg for 15 students and prints out the highest weight and the average weight of the students. The weights are in the range of 20kg to 140kg (inclusive). heaviest = 20 total_weight = 0 no_of_students = 15 for student in range(no_of_students): weight = float(input("Enter the weight of student in kg: ")) if heaviest < weight: heaviest = weight total_weight = total_weight + weight average_weight = total_weight/no_of_students print("Heaviest weight of th
Content continues in the PDF.
Related notes
- Computing o level notes Notes/Practices · 2023
- BVSS Prelim P1 CPExam Papers · 2024
- CWSS Prelim P1 CPExam Papers · 2024
- CWSS Prelim P1 MSExam Papers · 2024
- BVSS Prelim P1 MSExam Papers · 2024
- computing notesNotes/Practices

