示例#1
0
 def __init__(self, post_str, username, ratings, option):
     Post.__init__(self, post_str, username)
     self.ratings = ratings
     self.option = option
     count = 0
     rating = 0
     for r in ratings:
         rating += float(r)
         count += 1
     self.rating = f"{(rating/count):.2f}"
示例#2
0
 def __init__(self, post_str, username, body_part):
     Post.__init__(self, post_str, username)
     self.body_part = body_part
示例#3
0
 def __init__(self, post_str, username):
     Post.__init__(self, post_str, username)