Merge remote-tracking branch 'origin/saving_data' into saving_data

This commit is contained in:
2019-08-02 15:55:08 +02:00
2 changed files with 7 additions and 3 deletions
+2 -1
View File
@@ -42,8 +42,9 @@ try:
_subject = user_input[1]
subject_get = subject.get_subject(subjects, _subject)
user_IO.user_output(subject_get.return_average_subject)
elif input_or_output == "exit":
break
raise SystemError
except Exception as e:
print('ERROR' + str(e))
+4 -1
View File
@@ -1,5 +1,5 @@
def user_input():
todo = input("Ok, do you want to see them or to edit them [see/edit]?\n")
todo = input("Ok, do you want to see them or to edit them [see/edit/exit]?\n")
if todo == "see":
print("Which subject do you want to know the information?")
subject = input()
@@ -31,6 +31,8 @@ def user_input():
grade = input("Grade? \n")
grade_name = input("What's the name of the grade? \n")
return "input", "grade", subject, category, grade, grade_name
elif todo == "exit":
return "exit"
def user_output(subject, categories, average, average_subject):
@@ -43,6 +45,7 @@ def user_output(subject, categories, average, average_subject):
print(string + "\n")
print("The average of {} is {}.".format(subject, average_subject))
def password():
print("What is your password?")
return input()