All pastes #1278097 Raw Edit

analog clock

public python v1 · immutable
#1278097 ·published 2008-12-06 18:14 UTC
rendered paste body
t = raw_input()m = int(t[3:])h = int(t[0:2])c = ['o','o','o','o','o','o','o','o','o','o','o','o']if h>12:h=h-12if m>=0 and m<5:    c[11]='m'    a = 12elif m>=5 and m<10:    c[0]='m'    a=1elif m>=10 and m<15:    c[1]='m'    a=2elif m>=15 and m<20:    c[2]='m'    a=3elif m>=20 and m<25:    c[3]='m'    a=4elif m>=5 and m<30:    c[4]='m'    a=5elif m>=30 and m<35:    c[5]='m'    a=6elif m >= 35 and m < 40:    c[6]='m'    a=7elif m >= 40 and m < 45:    c[7]='m'    a=8elif m >= 45 and m < 50:    c[8]='m'    a=9elif m >= 50 and m < 55:    c[9]='m'    a=10elif m >= 55 and m <= 59:    c[10]='m'    a=11if h == a:    a=a-1    c=['o','o','o','o','o','o','o','o','o','o','o','o']    c[a]='x'elif h == 12: c[11] = 'h'elif h == 1: c[0] = 'h'elif h == 2: c[1] = 'h'elif h == 3: c[2] = 'h'elif h == 4: c[3] = 'h'elif h == 5: c[4] = 'h'elif h == 6: c[5] = 'h'elif h == 7: c[6] = 'h'elif h == 8: c[7] = 'h'elif h == 9: c[8] = 'h'elif h == 10: c[9] = 'h'elif h == 11: c[10] = 'h'print "        %s" % c[11]print "    %s       %s" % (c[10],c[0])print "\n %s             %s" % (c[9],c[1])print "\n%s               %s" % (c[8],c[2])print "\n %s             %s" % (c[7],c[3])print "\n    %s       %s" % (c[6],c[4])print "        %s" % c[5]