抽象时钟油画艺术家

c#求

using System;namespace M和钱体味告yClass{ public 继束城class Clock { public int Hour { get; private set;} public int Minute {get;private set;} public int Second {get;private set;} public Clock(){Hour = 0; Minute=0; Second = 调计叫首换第需践0;} public Clo可目陈误协难ck(int h, int m, int s){SetTime(h,m,s);} public string GetTime() { return string.Format("{0}点{1}分{2}秒", Hour, Minute, Second)黑记不体伟米快运; } public void S形品更策etTime(int h, int m,int s) { if(h<0 || h>=2程师类局所充4 ||m<0 ||m>=60||s<0||s>=60) throw new Exception("Out of range!"); Hour = h; Minute = m; Second =s; } }}




350
标签
显示验证码
没有账号?注册  忘记密码?