1lst = input().split(',')#can use any seperator value inside '' of split
2print (lst)
3#given input = hello,world
4#output: ['hello', 'world']
5#another example
6lst = input().split(' ; ')#can use any seperator value inside '' of split
7print (lst)
8#given input = hello ; world ; hi there
9#output: ['hello', 'world', 'hi there']
1##Write a Python program to input a string that is a list of words separated by commas.
2##Construct a dictionary that contains all these words as keys and their frequencies as values.
3##Then display the words with their quantities.
4
5lst = []
6d = dict()
7user = input ("enter a string ::-- ")
8lst = user.split(',')
9print("LIST ELEMENR ARE :: ",lst)
10l = len(lst)
11for i in range(l) :
12 c = 0
13 for j in range(l) :
14 if lst[i] == lst[j ]:
15 c += 1
16 d[lst[i]] = c
17print("dictionary is :: ",d)
18