0% found this document useful (0 votes)
10 views2 pages

Higher Difficulty Scenario Based Questions

The document presents two higher-difficulty scenario-based programming questions. The first question involves creating a Hospital Patient Management System that manages patient records, ensuring valid input and calculating service usage. The second question focuses on a University Course Registration System that tracks student enrollments, enforcing course limits and identifying students with the highest enrollments.

Uploaded by

muntasir3m
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
10 views2 pages

Higher Difficulty Scenario Based Questions

The document presents two higher-difficulty scenario-based programming questions. The first question involves creating a Hospital Patient Management System that manages patient records, ensuring valid input and calculating service usage. The second question focuses on a University Course Registration System that tracks student enrollments, enforcing course limits and identifying students with the highest enrollments.

Uploaded by

muntasir3m
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Higher-Difficulty Scenario-Based Questions

Question 1 (15 Marks) - Hospital Patient Management System


A hospital wants to manage patient records efficiently. The hospital stores patient names in a
one-dimensional (1D) array Patients[] and medical records in a two-dimensional (2D) array
Records[]. Each row in Records[] corresponds to a patient, and each column stores the number of
doctor visits, lab tests, and medications prescribed.

Write a program that meets the following requirements:


- Allows the number of patients to be input and stored (maximum 50 patients).
- Ensures that a patient's name is not left empty during input.
- Allows the number of doctor visits, lab tests, and medications to be input and stored for each
patient.
- Ensures that the number of doctor visits is at least equal to or greater than the number of lab tests
for any patient.
- Calculates the total number of medical services (visits + tests + medications) used by each patient.
- Identifies the patient(s) with the highest medical service usage.
- Outputs the name(s) of the patient(s) with the highest service usage and their total services used.

All inputs and outputs must contain suitable messages. You must use pseudocode or program code
and add comments to explain how your code works.

Question 2 (15 Marks) - University Course Registration System


A university manages student course enrollments each semester. The university stores student
names in a one-dimensional (1D) array Students[] and course registration data in a two-dimensional
(2D) array Courses[]. Each row in Courses[] corresponds to a student, and each column represents
the number of courses they enrolled in for a specific semester.

Write a program that meets the following requirements:


- Allows the number of students to be input and stored (maximum 100 students).
- Ensures that no student registers for more than 6 courses per semester.
- Ensures that each student registers for at least 3 courses per semester.
- Allows the student names and their enrolled courses per semester to be input and stored.
- Calculates and stores the total number of courses each student has taken in all semesters.
- Identifies the student(s) with the highest total course enrollments.
- Outputs the name(s) of the student(s) with the highest course enrollments and their total enrolled
courses.
All inputs and outputs must contain suitable messages. You must use pseudocode or program code
and add comments to explain how your code works.

You might also like