I would have written:
percent = 100
while True:
try:
pyc = int(input('enter pyc :'))
tpy = int(input('enter tpy:'))
percent = (pyc / tpy) * percent
break
except ZeroDivisionError as detail:
print 'Handling run-time error:', detail