ive wrote this code so far.
class batch: def _init_(self, batch_number, components_in_batch): self.batch_number = batch_number self.components_in_batch = components_in_batch class component: def _init_(self, type, size): self.type = type self.size = size def batch_number(): batch_number = batch_number + 1 print("batch number is " + currentDT.strftime("%d%m%y") + str(batch_number).zfill(4)) components_list = ["1 = Winglet Strut", "2 = Door Handle", "3 = Rudder Pin"] print(components_list) #if ( component == 1 # and size == 1 # ): # print("you have selected Winglet Strut A320 Series") #if component == 1 and size == 2: # print("you have selected Winglet Strut A320 Series") print("please select an option")# print("1 = create a batch") print("0 = exit") while True: choice = input("> ") if choice == '1': print("welcome to the program") break elif choice == '0': print("you have selected to exit program") break else: print("invalid choice") print() while True: print("what component?") component = input("> ") if component == '1': print("you have selected Winglet Strut.") break elif component == '2': print("you have selected Door Handle") break elif component == '3': print("you have selected Rudder Pin") break else: print("invalid choice") sizes_list = ["1 = A320 Series", "2 = A380 Series"] print(sizes_list) while True: print("Please select the size of the of the component") size = input("> ") if size == '1': print("you have selected the A320 Series") break elif size == '2': print("you have selected the A380 Series") break else: print("invalid choice") while True: if component == 1 and size == 1: print("you have selected Winglet Strut A320 Series") break elif component == 1 and size == 2: print("you have selected Winglet Strut A380 Series") break elif component == 2 and size == 1: print("you have selected Door Handle A320 Series") break elif component == 2 and size == 2: print("you have selected Door Handle A380 Series") break elif component == 3 and size == 1: print("you have selected Rudder Pin A320 Series") break elif component == 3 and size == 2: print("you have selected Rudder Pin A380 Series") break else: print("invalid process") breakit works until the last while loop it goes straight to invalid process on that one so not sure how to get it to read the results from the previous 2 while loops.