python学生管理システム1.0バージョン
7437 ワード
#
list_stuInf = []
#
def add() :
#
while True:
#
name = input(' ,q :')
# q
if name == 'q':
break
else:
#
list_stuInf.append(name)
print(list_stuInf)
continue
#
def modify():
#
for x in range(0, len(list_stuInf)):
rs = list_stuInf[x]
x = x + 1
print(' :%s :%s' % (x, rs))
while True:
#
y = int(input(' :'))
#
if y > x:
y = int(input(' , :'))
else:
#
a = input(' :')
y = y - 1
list_stuInf[y] = a
break
#
def delInf():
#
for x in range(0, len(list_stuInf)):
rs = list_stuInf[x]
x = x + 1
print(' :%s :%s' % (x, rs))
# ,
while True:
#
z = int(input(' :'))
#
if z > x:
y = int(input(' , :'))
else:
#
z = z - 1
del list_stuInf[z]
break
#
def display():
for x in range(0, len(list_stuInf)):
rs = list_stuInf[x]
x = x + 1
print(' :%s :%s' % (x, rs))
while True:
print(' 1.0 :')
print('1. ')
print('2. ')
print('3 3.1 ')
print('4. ')
print('0. ')
select = int(input(' :'))
while select < 0 or select >4:
select = float(input(' , '))
if select == 1:
#
add()
if select == 2:
modify()
if select == 3:
delInf()
if select == 4:
display()
if select == 0:
print(' !')
break