Пример #1
0
        static void Main(string[] args)
        {
            GSM newGsm = new GSM("Kiril", "Nokia");

            Console.WriteLine("Enter name on model:");
            newGsm.Model = Console.ReadLine();

            Console.WriteLine("Enter name on Price:");
            newGsm.Price = decimal.Parse(Console.ReadLine());

            Console.WriteLine("Enter battery model:");
            newGsm.Battery.BatteryModel = Console.ReadLine();

            Console.WriteLine("Enter hours idle:");
            newGsm.Battery.HoursIdle = int.Parse(Console.ReadLine());

            Console.WriteLine(newGsm.ToString());
        }
Пример #2
0
        static void Main(string[] args)
        {
            GSM newGsm = new GSM("Kiril", "Nokia");

            Console.WriteLine("Enter name on model:");
            newGsm.Model = Console.ReadLine();

            Console.WriteLine("Enter name on Price:");
            newGsm.Price = decimal.Parse(Console.ReadLine());

            Console.WriteLine("Enter battery model:");
            newGsm.Battery.BatteryModel = Console.ReadLine();

            Console.WriteLine("Enter hours idle:");
            newGsm.Battery.HoursIdle = int.Parse(Console.ReadLine());

            Console.WriteLine(newGsm.ToString());
        }