0% found this document useful (0 votes)
8 views

Group-13-Project-Report (2)

Uploaded by

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

Group-13-Project-Report (2)

Uploaded by

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

Green University of Bangladesh

Department of Computer Science and Engineering (CSE)


Semester: (Fall, Year: 2024), B.Sc. in CSE (Day)

Course Title: Computational thinking and problem solving


Course Code: CSE 100
Section: 242_D8
Students Details

Name ID
Khurshida Jahan Khushi 242002163

Submission Date: 24.12.2024

Course Teacher’s Name: Abrar Hassan. Lecturer , Green University O


f Bangladesh.

1. TITLE OF THE LAB REPORT EXPERIMENT


Bus Ticket Reservation System: Design and Implementation
This project focuses on creating a user-friendly bus ticket reservation system for both
administrators and travelers. The goal is to design and implement a system that allows
users to reserve bus seats, view available buses and seats, and perform necessary
operations such as canceling bookings. The project also includes file storage for
persistence.

2. OBJECTIVES/AIM
The primary aim of this experiment is to design and implement a bus ticket reservation
system that provides the following capabilities:

1.

Allow users to view available buses and their seat prices.


2.
3.
Enable users to select one or more available seats for booking.
4.
5.
Provide an accurate total price based on selected seats.
6.
7.
Mark seats as booked and prevent double booking.
8.
9.
Allow cancellation of reservations.
10.
11.
Allow administrators to manage available routes and seat pricing.

12.

3. PROCEDURE / DESIGN
4. The procedure followed in solving this problem includes:

Flowchart: A flowchart was created to outline the system flow from bus selection
to seat booking and payment.
Flowchart Steps:


Display available buses.


Allow the user to select a bus.


1
Display available seats for the selected bus.


User selects one or more seats.


Calculate the total price based on selected seats.


Allow the user to confirm the reservation.


Mark selected seats as booked.


Save the updated status of buses and seats.


Algorithm:


Initialize bus data (routes, prices, and seats).


Allow the user to interact with the system, view buses, and make
selections.


Implement the seat reservation and cancellation processes.


Update the bus and seat status accordingly.


Pseudocode:
mathematica

Start
Initialize buses with routes and prices
Display available buses
Select bus
Display available seats for the bus
Select seats
Calculate total price
Confirm reservation
Update seat availability
Save updated data
End

2
Calculation:


Total price calculation: Total Price = Number of Seats * Price
per Seat.

4. IMPLEMENTATION
Overview:
The system was implemented in C programming language. It includes bus data
management, seat reservations, price calculation, and user interaction. The program
initializes the bus data, displays available buses, allows users to select buses and seats,
and calculates the total cost.

Implementation Details:

Data Structures: A Bus structure is used to store bus information, including


routes, seat prices, and seat availability.


File Handling: Bus data is saved to and loaded from a file (bus_data.dat) for
persistence across program runs.


Seat Reservation Logic: After selecting seats, the system checks for availability
and updates the seat status accordingly. If a seat is already booked, the user is
notified.

5. TEST RESULT / OUTPUT


Tests Run:

1.

Test Case 1: View available buses.


2.

Input: No input required.


Expected Output: List of buses with route and price details.


Result: Passed, displayed correct bus information.
3

3.
Test Case 2: Reserve seats for a bus.
4.

Input: Bus ID = 1, Seats = 3 and 5.


Expected Output: Total price for 2 seats, seat status updated to booked.


Result: Passed, the total price was calculated correctly, and seats were
marked as booked.

5.
Test Case 3: Cancel a reservation.
6.

Input: Bus ID = 1, Seat = 3.


Expected Output: Seat 3 is available again.


Result: Passed, seat status updated to available.

7.
Test Case 4: View booked seats.
8.

Input: Bus ID = 1.


Expected Output: List of booked seats.


Result: Passed, correctly displayed the booked seats.

Summary of Results:
All tests passed successfully, confirming that the program works as expected.

Bugs:

There were no significant bugs during testing, though some minor input validation
(e.g., for incorrect seat numbers) could be improved.

4

6. ANALYSIS AND DISCUSSION


Analysis of Results:

The system successfully handles bus selection, seat booking, and payment
processing. The user interface is clear and easy to navigate.

What Went Well?:

The seat reservation process was smooth and intuitive.




File handling worked well for data persistence.

Trouble Spots:

Handling input validation was somewhat tricky, especially for edge cases such as
invalid seat numbers or non-numeric inputs.


Implementing the cancel reservation feature required careful seat status
management to ensure accuracy.

Most Difficult Parts:

Implementing seat availability checks and ensuring that the system prevents
double-booking was complex.


Managing data persistence using file operations was challenging, especially when
ensuring that data is saved and loaded correctly.

What Did You Like About the Assignment?:

5
I enjoyed designing the system and creating a functional user interface. The
challenge of managing seat bookings and cancellations was also enjoyable.

What Did You Learn?:

I learned how to handle file operations in C, manage dynamic user input, and
implement reservation systems. This project also enhanced my problem-solving
skills.

Mapping of Objective:

All objectives have been met: users can view buses, select and reserve seats,
and manage their reservations effectively.

7. SUMMARY (Optional)
This report details the design and implementation of a Bus Ticket Reservation System,
which meets the outlined objectives and provides a simple, effective solution for bus seat
management. The system was tested and found to work correctly, with all major features
functioning as expected. The project provided valuable experience in file handling, input
validation, and algorithm design.

You might also like