#!/usr/bin/env python
import os,sys,random
ball=[]
out_ball=[]
bule_ball=[]
try:
for i in range(1,34):
ball.insert(i-1,i)
for i in range(1,17):
bule_ball.insert(i-1,i)
print "Ball is:"
for i in range(0,6):
os.system("sleep "+str(random.randint(1,6)))
out_ball.insert(i,ball.pop(int(random.random()*(33-i))))
out_ball.sort()
for i in range(0,6):
os.system("sleep 1")
sys.stdout.write("\033[41;63m "+str(out_ball[i])+" \033[0m ")
sys.stdout.flush()
for i in range(0,1):
os.system("sleep "+str(random.randint(1,6)))
sys.stdout.write( "\033[44;44m "+str(ball.pop(int(random.random()*(16-i))))+" \033[0m\n")
except:
print "System happend Error,pls retry!"
~