예제 #1
0
파일: shell.py 프로젝트: pengdake/code
#!/usr/bin/env python
#-*-coding:utf-8-*-
import root_test
import config
while 1:
    status=raw_input('please enter your status:')
    if config.STATUS_RIGHT.has_key(status):
        if status==config.ROOT_NAME:
            i=3
            while i>0:
                password=raw_input('please enter your password:'******'you have %d choice'%i
                    continue
            print 'bye-bye'
        else:
            root_test.test(status,config)
    elif status=='exit':
        break
    else:
        print 'error status,please try again!'
예제 #2
0
파일: shell.py 프로젝트: pengdake/code
import config
status=raw_input('please enter your status:')
if status=='root':
    i=3
    while i>0:
        password=raw_input('please enter your password:'******'you have %d choice'%i
            continue
    print 'bye-bye'
elif status=='student':
    import student_test
    student_test.test()
elif status=='teacher':
    import  teacher_test
    teacher_test.test()
else:
    print 'error status,please try again!'