BVSS 2020 P2 Solution
Uploaded by IDKWHYBUTIAM · 3 November 2024
Preview
1 Task 1 – 10 marks 1 =HLOOKUP(B3, $B$14:$G$15, 2, FALSE)*C3 =HLOOKUP(B4, $B$14:$G$15, 2, FALSE)*C4 =HLOOKUP(B5, $B$14:$G$15, 2, FALSE)*C5 =HLOOKUP(B6, $B$14:$G$15, 2, FALSE)*C6 =HLOOKUP(B7, $B$14:$G$15, 2, FALSE)*C7 =HLOOKUP(B8, $B$14:$G$15, 2, FALSE)*C8 2 =SUM(D3:D8) 3 =IF(D3>=500, "Yes", "No") =IF(D4>=500, "Yes", "No") =IF(D5>=500, "Yes", "No") =IF(D6>=500, "Yes", "No") =IF(D7>=500, "Yes", "No") =IF(D8>=500, "Yes", "No") 4 =COUNTIF(E3:E8, "Yes") OR =COUNTIF(D3:D8, ">500") 5 =20%*D10*12 6 =-FV(1/12*3.88%, 3*12, 0, 30000) 7 =IF(B17*3 >=B19, "able", "unable") OR =IF(B19>B17*3, "unable", "able")
2 Task 2 Q8(a), (b), (c) – 7 marks num_low = 0 num_med = 0 num_high = 0 number = int(input('Enter a positive integer: ')) while number != 0: valid = False while valid == False: if number < 0 or number > 100: print('Numbers must be between 1 to 100 inclusive') number = int(input('Enter a positive integer: ')) else: valid = True if number > 0 and number <= 30: print(number, '- Low') num_low = num_low + 1 elif number > 30 and number <= 70: print(number, '- Medium') num_med = num_med + 1 elif number > 70 and number <= 100: print(number, '- High') num_high = num_high + 1 number = int(input('Enter a positive integer: ')) print("There are", num_low, "number(s) in Low category") print("There are", num_med, "number(s) in Medium category") print("There are", num_high, "number(s) in High category")
3 Task 2 Q9 – 3 marks num_low = 0 num_med = 0 num_high = 0 upper_limit = int(input("Enter a upper limit: ")) number = int(input('Enter a positive integer: ')) while number != 0: valid = False while valid == False: if number < 0 or number > upper_limit: print('Numbers must be between 1 to', upper_limit, 'inclusive') number = int(input('Enter a positive integer: ')) else: valid = True if number > 0 and number <= 30: print(number, '- Low') num_low = num_low + 1 elif number > 30 and number <= 70: print(number, '- Medium') num_med = num_med + 1 elif number > 70 and number <= upper_limit: print(number, '- High') num_high = num_high + 1 number = int(input('Enter a positive integer: ')) print("There are", num_low, "number(s) in Low category") print("There are", num_med, "number(s) in Medium category") print("There are", num_high, "number(s) in High category")
4 Task 3 – 10 marks month_abbr = ['Jan','Feb','Mar','Apr','May','Jun', 'Jul','Aug','Sep','Oct','Nov','Dec'] day = int(input("Enter the day: ")) # validate day # while day < 1 or day > 31: day = int(input("Invalid date. Re-enter the day: ")) month = int(input("Enter the month: ")) #validate month while month < 1 or month > 12: month = int(input("Invalid month. Re-ente
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

