Question: The objective of Assignment 3 is to practice functions, lists, and files. It does not require the use of any external libraries or modules. Problem

The objective of Assignment 3 is to practice functions, lists, and files. It does not require the use of any external libraries or modules.
Problem Description:
International Transport Company (ITC) operates a bus service providing passenger transportation both within cities (intracity) and between cities (intercity). ITC has established time schedules for buses to reach their destinations on time. While delays due to traffic or other reasons are expected, arriving early suggests that drivers may be either driving excessively fast or not allocating sufficient time at intermediate stations. Therefore, ITC has decided to identify drivers who arrive before the scheduled time and impose a penalty of 25 RO for each instance of early arrival.
A sample input text file named 'DayToDayRegister.txt' is available on Moodle. The file contains fields as shown in the following figure, which shows the first few lines of the input file:
\table[[Bus Route,Emp Id,Name,\table[[Scheduled],[Time]],\table[[Arrival],[Time]]],[1,2210,Khamis,5:00,5:00
Sample run/output:
\table[[\table[[Screen 1:],[\table[[International Transport Company],[1. Display information by bus route],[1. Display information emp id],[3. Early coming drivers],[4. Penalty on Early coming Drivers],[5. Drivers of the day],[6. Exit],[Enter Your Choice : 8],[Invalid Input],[International Transport Company],[2.],[1. Display information by bus route],[2. Display information emp id],[3. Early coming drivers],[4. Penalty on Early coming Drivers],[5. Drivers of the day],[6. Exit],[Enter Your Choice :]]]]],[],[]]
Screen 2:
q, International Transport Company
Display information by bus route
Display information empl id
Early coming drivers
Penalty on Early coming Drivers
Drivers of the day
Exit
Enter Your Choice : 1
Enter the bus route number: 2
EmpId Name Scheduled time Arrival time
Saif
6:00
6:10
7:30
9:30
11:15
13:40
Screen 4:
The objective of Assignment 3 is to practice functions, lists, and files. It does not require the use of any external libraries or modules.
Problem Description:
International Transport Company (ITC) operates a bus service providing passenger transportation both within cities (intracity) and between cities (intercity). ITC has established time schedules for buses to reach their destinations on time. While delays due to traffic or other reasons are expected, arriving early suggests that drivers may be either driving excessively fast or not allocating sufficient time at intermediate stations. Therefore, ITC has decided to identify drivers who arrive before the scheduled time and impose a penalty of 25 RO for each instance of early arrival.
A sample input text file named 'DayToDayRegister.txt' is available on Moodle. The file contains fields as shown in the following figure, which shows the first few lines of the input file:
\table[[Bus Route,Emp Id,Name,\table[[Scheduled],[Time]],\table[[Arrival],[Time]]],[1,2210,Khamis,5:00,5:00
The objective of Assignment 3 is to practice

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!