Please.. I need the code..
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend4days leftRegister
Pankaj Kumar ChoudharyRank #80 · 24.4K reputationPosted May 19, 2015, 4:05 AM EDT
{
double Total_Purchase=0;
Dictionary
Dictionary
Products["AAA"] = 5.00;
Products["BBB"] = 7.00;
Products["CCC"] = 2.30;
Products["DDD"] = 1.70;
Products["EEE"] = 9.00;
Product_Sold["BBB"] = 2;
Product_Sold["DDD"] = 4;
Product_Sold["EEE"] = 1;
Console.WriteLine(" " + "My Street Shop \n");
Console.WriteLine("ProdCode Quantity Price Amount(RM)");
foreach (KeyValuePair
{
foreach (KeyValuePair
{
if (Sell.Key == Prod.Key)
{
Console.WriteLine(" "+Sell.Key + " " + Sell.Value + " " + Prod.Value + " " + (Sell.Value * Prod.Value));
Total_Purchase += Sell.Value * Prod.Value;
break;
}
}
}
Console.WriteLine("\n\n Total Purchase =RM{0}", Total_Purchase);
Console.ReadLine();
}
Pankaj Kumar ChoudharyRank #80 · 24.4K reputationPosted May 18, 2015, 10:02 AM EDT
Vincent Maverick DuranoRank #238 · 10.3K reputationPosted May 18, 2015, 10:09 AM EDT
Pankaj Kumar ChoudharyRank #80 · 24.4K reputationPosted May 18, 2015, 7:55 PM EDT
Vincent Maverick DuranoRank #238 · 10.3K reputationPosted May 19, 2015, 1:23 AM EDT
Providing you codes will not help you either and you are not helping yourself. I'd suggest you to start learning the basics and understand how stuff works. Learn one step at a time. Now if you are having confusions about the code that you've tried then that's the time for you to post your query here.
I'd also suggest to give this article a read: http://www.c-sharpcorner.com/UploadFile/8c19e8/programming-problems-and-finding-solutions/
Amex Johnny20 reputationPosted May 18, 2015, 3:21 PM EDT
Amex Johnny20 reputationPosted May 18, 2015, 3:28 PM EDT
Amex Johnny20 reputationPosted May 19, 2015, 3:17 AM EDT
Amex Johnny20 reputationPosted May 19, 2015, 6:10 AM EDT