Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

Ride Management System

A C++ console application simulating a ride-hailing service similar to Uber. This project demonstrates object-oriented programming concepts including inheritance, polymorphism, and encapsulation.

Features

  • User Authentication: Register new accounts or login with existing credentials
  • Vehicle Selection: Choose from three vehicle types with different pricing:
    • Moto: Base fare ₨40 for ≤2km, ₨15/km thereafter
    • Uber Mini: Base fare ₨60 for ≤2km, ₨35/km thereafter
    • Uber Go: Base fare ₨100 for ≤2km, ₨45/km thereafter
  • Ride Simulation: Random distance generation, fare calculation, and driver availability
  • Wallet Management: Track payment and remaining balance
  • Feedback System: Rate your ride experience
  • Polymorphic Fare Calculation: Uses inheritance and virtual functions for different vehicle types

Requirements

  • C++ compiler (g++, MinGW, or Visual Studio)
  • Windows OS (for system commands like COLOR and Beep)

Building and Running

  1. Ensure you have a C++ compiler installed (e.g., g++, MinGW, or Visual Studio)
  2. Ensure the project structure is intact, with the libs directory containing the header files
  3. Compile the project:
    g++ project2.cpp -o ride_management
    
  4. Run the executable:
    ride_management.exe
    

Usage

  1. Registration/Login:

    • Choose 'S' to sign up or 'L' to login
    • For signup: Enter name, age, email, and password
    • For login: Enter email and password
  2. Book a Ride:

    • Enter pickup and drop locations
    • Select vehicle type (1-3)
    • View ride details including distance, fare, and active drivers
  3. Payment and Feedback:

    • Enter payment amount
    • Rate your experience (1-5 stars)
    • View remaining wallet balance

Project Structure

  • project2.cpp: Main application file containing all classes and logic
  • libs/register.h: Header file for user registration functionality
  • libs/loginacc.h: Header file for user login functionality

Classes Overview

  • VehicleType: Abstract base class for vehicles (polymorphism)
  • MotoType, UberMiniType, UberGoType: Derived vehicle classes
  • Register: Handles user registration
  • login: Handles user authentication
  • Account: Combines registration and login, manages wallet
  • Ride: Main ride management class inheriting from Account

Notes

  • This is a console-based simulation for educational purposes
  • Distances are randomly generated for demonstration
  • The application uses Windows-specific functions (Beep, system("COLOR"))

Credits

Developer: AsadDevs

This project was developed as part of the 2nd Semester Object-Oriented Programming (OOP) course at NCBAE (National College of Business Administration & Economics).

Author Information

  • Name: AsadDevs
  • Institution: NCBAE (National College of Business Administration & Economics)
  • Course: Object-Oriented Programming (OOP) - 2nd Semester
  • Project Type: Educational Console Application

Disclaimer

This is an educational project developed for learning purposes. The ride-hailing simulation is not intended for production use or real-world deployment. All pricing and vehicle types are fictional and used solely for demonstration of OOP concepts.

License

This project is provided as-is for educational purposes. Please contact the developer for licensing inquiries.

Support & Contact

For questions, bug reports, or contributions related to this project, please reach out to the developer.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages