الینا:)
کاربر حرفهای
- ارسالها
- 506
- امتیاز
- 4,672
- نام مرکز سمپاد
- فرزانگان
- شهر
- بابل
- سال فارغ التحصیلی
- 1400
Python:
game1 = int(input('Score= '))
game2 = int(input('Score= '))
game3 = int(input('Score= '))
game4 = int(input('Score= '))
game5 = int(input('Score= '))
game6 = int(input('Score= '))
game7 = int(input('Score= '))
game8 = int(input('Score= '))
game9 = int(input('Score= '))
game10= int(input('Score= '))
game11 = int(input('Score= '))
game12 = int(input('Score= '))
game13 = int(input('Score= '))
game14 = int(input('Score= '))
game15 = int(input('Score= '))
list1=[game1,game2,game3,game4, game5, game6, game7, game8 ,game9, game10, game11, game12, game13, game14, game15]
number_count= list1.count(3)
for n in list1 :
print(n)
jam = game1 + game2 + game3 + game4 + game5+ game6 + game7+ game8+ game9+ game10+ game11+ game12+ game13+game14+ game15
print('the total score is ',jam, 'there were', number_count,'wins')