Why the code below generate error (cs1061), when I run it in solo learn, but it is ok when I run it in my laptop?
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace SoloLearn { class Program { static void Main(string[] args) { int discount = Convert.ToInt32(Console.ReadLine()); Dictionary<string, int> coffee = new Dictionary<string, int>(); coffee.Add("Americano", 50); coffee.Add("Latte", 70); coffee.Add("Flat White", 60); coffee.Add("Espresso", 60); coffee.Add("Cappuccino", 80); coffee.Add("Mocha", 90); //your code goes here int r; double d; foreach(string c in coffee.keys) { d=(double)discount/100; r=(Int32)((1-d)*coffee[c]); Console.WriteLine("{0}: {1}", c, r); } } } }