Beispiel #1
0
 static void Main(string[] args)
 {
     Radio radio = new Radio();
     radio.OnOff = true;
     radio.Volume = 7;
     radio.Frequency = 22000;
     Console.WriteLine(radio.ToString());
     Console.ReadLine();
 }
Beispiel #2
0
        static void Main(string[] args)
        {
            Radio radio = new Radio();
            radio.OnOff();
            radio.Volume = 4;
            radio.Frequency = 56000.0;
            radio.Frequency = 1300.0;
            radio.Frequency = 2400.0;
            radio.PrintData();
            Console.ReadLine();


        }
Beispiel #3
0
        static void Main(string[] args)
        {
            Radio radio = new Radio();

            Console.WriteLine("Power: " + radio.Power);
            radio.Power = true;
            Console.WriteLine("Power: " + radio.Power);

            Console.WriteLine("Vol: " + radio.Volume);
            radio.Volume = 9;
            Console.WriteLine("Vol: " + radio.Volume);

            Console.WriteLine("Freq: " + radio.Frequency);
            radio.Frequency = 26000.1;
            Console.WriteLine("Freq: " + radio.Frequency);
        }
Beispiel #4
0
        static void Main(string[] args)
        {
            Radio a = new Radio();

            Console.WriteLine(a.ToString());
            a.PowerSwitch = true;
            a.Volume      = 100;
            Console.WriteLine(a.ToString());
            a.Volume = 9;
            Console.WriteLine(a.ToString());
            a.Frequency = 27000;
            Console.WriteLine(a.ToString());
            a.Frequency = 26000.1;
            Console.WriteLine(a.ToString());
            a.Frequency = 1500;
            Console.WriteLine(a.ToString());
            a.Frequency = 5000.30;
            Console.WriteLine(a.ToString());
        }