COMPREHENSION TASK
EXIT = False while (EXIT is not True ): start_exit = input ( "Enter S for Start Enter E for Exit: " ) if start_exit == 'E' : exit () elif start_exit == 'S' : no_of_item = int ( input ( "Enter Number of Item want in list: " )) input_string = input ( "Enter a list element separeted by space: " ) list = input_string.split( " " ) if len (list)>no_of_item: print ( "Maximum Element Entry" ) elif len (list)<no_of_item: print ( "Minimum Element Entry" ) else : t = int ( input ( "Which type of comprehension you want to use \n 1 for list, 2 for Dictionary and press 3 for set: " )) if t == 1 : ls = [i for i in list] print (ls) print ( type (ls)) elif t == 2 : dic = { f"item { i } " : i for i in list} ...