using System.Collections.Generic;
static List<int> ProID = new List<int>();
static List<string> Name = new List<string>();
static List<int> Quant = new List<int>();
static List<double> Price = new List<double>();
public static void Main()
Console.WriteLine("Welcome to the Inventory Management System , HamzyManage");
Console.WriteLine(" Please choose an option: \n 1. Add a product \n 2. Update product stock \n 3. View all products \n 4. View product by ID \n 5. Generate sales report \n 6. Exit ");
string input = Console.ReadLine();
public static void Proadd()
Console.WriteLine("Whats your new product Name?");
string input = Console.ReadLine();
Console.WriteLine("Whats your product quantity");
int input2 = Convert.ToInt32(Console.ReadLine());
Console.WriteLine("What will you list your product price at ");
double input3 = Convert.ToDouble(Console.ReadLine());
Console.WriteLine("Name: " + Name[id3] + "\n" + "Quantity: " + Quant[id3] + "\n" + "Price: " + Price[id3] + "\n" + "ID: " + ProID[id3] );
Console.WriteLine("Product successfully added!");
public static void Prostock()
Console.WriteLine("What is the ID of the product stock do you want to update");
int input = Convert.ToInt32(Console.ReadLine());
Console.WriteLine("What is the new quantity?");
int input2 = Convert.ToInt32(Console.ReadLine());
int index = ProID.IndexOf(input);
Console.WriteLine("Name: " + Name[index] + "\n" + "Quantity: " + Quant[index] + "\n" + "Price: " + Price[index] + "\n" + "ID: " + ProID[index] );
Console.WriteLine("Error");
public static void Proview()
foreach (string a in Name)
Console.WriteLine("Product Name: " + a);
Console.WriteLine("Product Quantity: " + b);
foreach (double c in Price)
Console.WriteLine("Product Price: " + c);
Console.WriteLine("Product ID: " + d);
public static void ProviewID()
Console.WriteLine("What is the ID of the product?");
int input = Convert.ToInt32(Console.ReadLine());
int index = ProID.IndexOf(input);
Console.WriteLine("Product Name: " + Name[index] + "\n" + "Product Quantity: " + Quant[index] + "\n" + "Product Price: " + Price[index] + "\n" + "Product ID: " + ProID[index] );
Console.WriteLine("Error");
public static void ProSales()
for (int i = 0 ; i < ProID.Count ; i++)
Console.WriteLine("Enter quantity sold for " + Name[i] + "(ID : " + ProID[i] + ")" );
int quantsold = Convert.ToInt32(Console.ReadLine());
double sale = quantsold * Price[i];
totalsales = totalsales + sale;
Console.WriteLine("Sales report: " + totalsales);
public static void Exit()
Console.WriteLine("Bye!");