You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
26 lines
924 B
26 lines
924 B
class summaryDataOut:
|
|
confirmed=0
|
|
died=0
|
|
curConfirm=0
|
|
cured=0
|
|
confirmedRelative=0
|
|
curedRelative=0
|
|
diedRelative=0
|
|
curConfirmRelative=0
|
|
relativeTime=0
|
|
time=''
|
|
|
|
def blankNum (self,object):
|
|
return ' '*(12-len(str(object)))
|
|
|
|
def PrintOut(self):
|
|
print("截至%s国外疫情概况:"%self.time)
|
|
print("现有确诊:%d" % self.curConfirm, end=self.blankNum(self.curConfirm))
|
|
print("相对昨日新增:%d"%self.curConfirmRelative)
|
|
print("累计确诊:%d"%self.confirmed,end=self.blankNum(self.confirmed))
|
|
print("相对昨日新增:%d"%self.confirmedRelative)
|
|
print("累计治愈:%d"%self.cured,end=self.blankNum(self.cured))
|
|
print("相对昨日新增:%d"%self.curedRelative)
|
|
print("累计死亡:%d"%self.died,end=self.blankNum(self.died))
|
|
print("相对昨日新增:%d"%self.diedRelative)
|