-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmenu.py
28 lines (24 loc) · 1017 Bytes
/
menu.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
from bruteforce import bruteforce_main
from optimization_branch_bound import optimization_bb_main
from optimization_greedy import optimization_main
def run_menu():
while True:
print(" ---------------------------------------------------------------")
print(" ** MAIN MENU **", end='\n\n')
print(" chose a file or exit the program:")
print(" 1. bruteforce.py")
print(" 2. optimization_greedy.py")
print(" 3. optimization_branch_bound.py")
print(" 4. Quit program", end='\n\n')
choice = int(input(" Please enter your choice of the file: "))
print()
if choice == 1:
bruteforce_main('bruteforce')
elif choice == 2:
optimization_main('optimization_greedy')
elif choice == 3:
optimization_bb_main('optimization_branch_bound')
elif choice == 4:
break
else:
print(" Invalid choice. Please enter a number between 1 and 2.", end='\n\n')