GithubHelp home page GithubHelp logo

abdulrahmanfares / flightticketbookingapplicationinjava Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 4 KB

The Flight Booking System is a Java console application for managing flight tickets. It allows users to book and cancel tickets for two flights, with dynamic pricing based on demand. The system provides functionality to view and print details of booked tickets, ensuring a straightforward and interactive user experience.

License: MIT License

Java 100.00%

flightticketbookingapplicationinjava's Introduction

Flight Booking System

This is a simple console-based Flight Booking System implemented in Java. The system allows users to book, cancel, and print details of flight tickets. It supports two flights with a fixed number of tickets and cost per ticket. The system also keeps track of passenger details and provides a refund for canceled tickets.

Features

  • Book tickets for Flight 1 or Flight 2.
  • Cancel tickets with a refund, decreasing the ticket price by 200 for each cancellation.
  • Print details of booked tickets for both flights.
  • Exit the program.

Usage

  1. Compile and run the Java program (Main.java) using your preferred IDE or command line.
  2. Choose the desired option:
    • Book tickets
    • Cancel tickets
    • Print details
    • Exit

Book Tickets

  • Enter the flight number (1 or 2).
  • Specify the number of tickets to book.
  • The system checks availability and provides booking details.

Cancel Tickets

  • Enter the flight number (1 or 2) and passenger ID.
  • The system checks validity and provides a refund for canceled tickets, decreasing the ticket price by 200 for each cancellation.

Print Details

  • Displays details of booked tickets for both flights.

Exit

  • Terminates the program with a "Thank you!" message.

Note

  • Flight 1 and Flight 2 have a fixed number of tickets and an initial cost per ticket.
  • The cost per ticket increases by 200 for each booked ticket.
  • The ticket price decreases by 200 for each canceled ticket.

Issues and Contributions

If you encounter any issues or have suggestions for improvement, feel free to open an issue or submit a pull request.

License

This project is licensed under the MIT License.

Support

If you find this project helpful or would like to contribute to its continued development, consider supporting me with a coffee! Your support is invaluable.

Buy Me a Coffee

flightticketbookingapplicationinjava's People

Contributors

abdulrahmanfares avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.