C\

From , 3 Years ago, written in C#, viewed 179 times.
URL https://pastebin.vip/view/3b922393
  1. public class Plane {
  2.       protected double mySpeed = 300.0D;
  3.       public double TopSpeed {
  4.                               get {return mySpeed;}
  5.                               set { mySpeed = value; }
  6.                               }
  7.    }
  8.    class Jet : Plane {
  9.       public Jet() { TopSpeed = 900.0D; }
  10.    }
  11.       class Airport {
  12.       [STAThread]
  13.       static void Main(string[] args) {
  14.          Plane plane = new Plane();
  15.          Console.WriteLine("plane's top speed: {0}",plane.TopSpeed);
  16.          Jet jet = new Jet();
  17.          Console.WriteLine("jet's top speed: {0}",jet.TopSpeed);
  18.          Console.ReadLine();
  19.       }
  20.    }
  21. //csharp/4822

Reply to "C\"

Here you can reply to the paste above

captcha

https://burned.cc - Burn After Reading Website