A console-based Inventory & Sales Tracker developed in C++ for the CS118 – Programming Fundamentals (Fall 2025) course at FAST NUCES.
The application allows small businesses to manage product inventory, record sales, track revenue, and store data permanently using text files. It is built using only Programming Fundamentals concepts such as arrays, functions, structures, loops, conditional statements, and file handling.
- Add new products
- Update product price and quantity
- Delete products
- Prevent duplicate Product IDs
- Display all products
- Search products by ID
- Search products by Name
- Prevent negative inventory
- Validate user input
- Record product sales
- Automatically reduce available stock
- Calculate total bill
- Prevent selling more than available stock
- Display sales history
- Show top-selling product(s)
- Calculate total revenue
- Save product data to
products.txt - Save sales data to
sales.txt - Automatically load saved data when the program starts
- C++
- Arrays
- Structures
- Functions
- File Handling
- Console Application
===== Inventory & Sales Tracker =====
1. Add Product
2. Display Products
3. Update Product
4. Delete Product
5. Search Product
6. Record Sale
7. Display Sales
8. Top Selling Product
9. Total Revenue
10. Save & Exit
- Structures (
struct) - Arrays
- Functions
- Loops
- Conditional Statements
- Input Validation
- File Handling (
ifstream&ofstream) - String Manipulation (
cstring) - Formatted Output (
iomanip)