Skip to content

Instantly share code, notes, and snippets.

@MishoG
Created November 21, 2014 12:38
Show Gist options
  • Save MishoG/043226f7cdbd0dee0f7f to your computer and use it in GitHub Desktop.
Save MishoG/043226f7cdbd0dee0f7f to your computer and use it in GitHub Desktop.
ამოცანა 1
a = int(input('sheiyvanet ricxvi: '))
b = int(input('sheiyvanet ricxvi: '))
c = int(input('sheiyvanet ricxvi: '))
numbers = [a, b, c]
print ("uaryopiti ricxvebis raodenobaa: ")
print sum(1 for number in numbers if number < 0)
print 'shedegi :'
if a > 0:
print 2 * a
elif a < 0:
print a ** 2
else:
print 0
if b > 0:
print 2 * b
elif b < 0:
print b ** 2
else:
print 0
if c > 0:
print 2 * c
elif c < 0:
print c ** 2
else:
print 0
raw_input('press enter')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment