欧美性猛交XXXX免费看蜜桃,成人网18免费韩国,亚洲国产成人精品区综合,欧美日韩一区二区三区高清不卡,亚洲综合一区二区精品久久

打開(kāi)APP
userphoto
未登錄

開(kāi)通VIP,暢享免費電子書(shū)等14項超值服

開(kāi)通VIP
unknown
using System;
namespace dirtysalt
{
 public class Car//class of car,has attribute of 'weight' and 'speed'
 {
  private int weight;
  private int speed;
  public Car(int Weight,int Speed)
  {
   weight=Weight;
   speed=Speed;
  }
  public void setweight(int Weight)
  {
   weight=Weight;
  }
  public void setspeed(int Speed)
  {
   speed=Speed;
  }
  public int getspeed()
  {
   return speed;
  }
  public int getweight()
  {
   return weight;
  }
 };

 public class Sportcar:Car//inherit class of Car,has  attributes of 'weight','speed','color'
 {
  private string color;
  public  Sportcar(int Weight,int Speed,string Color):base(Weight,Speed)
  {
   setweight(Weight);
   setspeed(Speed);
   color=Color;
  }
  public void setcolor(string Color)
  {
   color=Color;
  }
  public string getcolor()
  {
   return color;
  }
  public static void Main()
  {
   Car car=new Car(100,100);
   Sportcar sportcar=new Sportcar(100,200,"blcak");//here has a problem
   Console.WriteLine("car's weight is "+car.getweight());
   Console.WriteLine("car's speed is "+car.getspeed());
   Console.WriteLine("sportcar's weight is "+sportcar.getweight());
   Console.WriteLine("sportcar's speed is "+sportcar.getspeed());
   Console.WriteLine("sportcar's speed is "+sportcar.getcolor());
  }
 }
}
 
本站僅提供存儲服務(wù),所有內容均由用戶(hù)發(fā)布,如發(fā)現有害或侵權內容,請點(diǎn)擊舉報。
打開(kāi)APP,閱讀全文并永久保存 查看更多類(lèi)似文章
猜你喜歡
類(lèi)似文章
面向對象設計(二)——對象間的關(guān)系引發(fā)的思考
C#中ToDictionary,ToLookup
數據結構與算法:04 C#面向對象設計 II
Kruskal 最小生成樹(shù)算法
C#中要使一個(gè)類(lèi)支持FOREACH遍歷,實(shí)現過(guò)程怎樣?
c 類(lèi)與c#類(lèi)的區別
更多類(lèi)似文章 >>
生活服務(wù)
分享 收藏 導長(cháng)圖 關(guān)注 下載文章
綁定賬號成功
后續可登錄賬號暢享VIP特權!
如果VIP功能使用有故障,
可點(diǎn)擊這里聯(lián)系客服!

聯(lián)系客服

欧美性猛交XXXX免费看蜜桃,成人网18免费韩国,亚洲国产成人精品区综合,欧美日韩一区二区三区高清不卡,亚洲综合一区二区精品久久