#!/usr/bin/env python
# _*_ coding:utf-8 _*_
import sys
import os
#系统的用户登录
#os.system('clear')
time = 0
while True: #this is login
if time < 3:
name = raw_input(" 33[1mplease input your login account:").strip()
passwd = raw_input(" 33[1mplease input your login password:").strip()
if len(name) == 0: #.strip()意为去除空格
print(" 33[31mIt's not allow empty input!n")
continue
elif name == 'zhangjun' and passwd == '123.com':
print(" 33[32mYour account and password right!")
pass
else:
print(" 33[31mYour account or password error!")
time += 1
continue
break
else:
print(" 33[31mYou are wrong three times, has already quit from the system!")
sys.exit()
#系统的选择界面
#os.system('clear')
print ('n')
def display(): #进行登陆后界面的函数定义,方便在下面的选用层级后,返回上一层时,依然可以看到选择大屏。
print(" 33[34m########################################################################")
print(" 33[34mt######### 33[1;32mWelcome to this employee search system! 33[0;34m #########")
print(" 33[34mtt#################################################")
print("n")
print(" 33[32m 33[1mttt1 33[33m 33[1m.Search.(you can search the infomation for employee!)n")
print(" 33[32m 33[1mttt2 33[33m 33[1m.Add.(Add a user into this employee system!)n")
print(" 33[32m 33[1mttt3 33[33m 33[1m.Delete.(Delete a user from this employee system!)n")