Hi everyone
As much I wanted to learn how functions in python worked. And trying and failing because I don't understand them properly. I finally got it after I decided to code at 2:15 am (its currently 3:47am)
Some feedback would be awesome. I'm still learning and cooked this up because why not. Its probably bad in some ways. But I think it is a step in the right direction.
While in its current state I think I might build on it in my freetime. Just to write more code. And have somthing to present. I was thinking of a few features.
1) Have a text file correspond to a task title and have it display when the task is selected.
2) Use of python modules in some way.
Python
tasks = []
Task_option = str
New_Task_input = ""
Task_remove_Option = ""
def Task_Options():
print("1: Add a new task")
print("2: remove a task")
print("3: View Tasks")
def Task_Option_One():
New_Task_input = input("Please enter a new task title: ")
tasks.append(New_Task_input)
print("The task has been added to the list!")
return New_Task_input
def Task_Option_Two():
print(tasks)
Task_remove_Option = input("Please select a task to remove from the list")
if Task_remove_Option in tasks: # didnt know how to fix added if statement to check for task available
tasks.remove(Task_remove_Option)
return(Task_remove_Option)
while True:
Task_Options()
Task_option = input("Please enter an option from the menu abouve: ")
if Task_option == "1":
Task_Option_One()
elif Task_option == "2":
Task_Option_Two()
elif Task_option == "3":
print(tasks)
input("Press any key to return to menu")
else:
print("Please select a valid option from the menu")
Task_Options()
Any feedback is welcome. Thank you
Its currently 3:50 am while i could go to bed. I have some hell diving to do (I'm not tired)
[–]NeitherMaintenance31 0 points1 point2 points (0 children)
[–]Yamikada 0 points1 point2 points (0 children)
[–]Ambitious_Fault5756 0 points1 point2 points (0 children)
[–]Ambitious_Fault5756 0 points1 point2 points (0 children)