# dictionary is nothing but key value is pairs
# d1 = {}
# print(type(d1))
# d2 = {"santosh" : "roti", "amit" : "mutton", "roshan" : "chawal", "balveer" : {"L" : "machchi", "d" : "murga", }}
# d2["aslam"] = "biryani"
# del d2["aslam"]
# print(d2)
# d3 = d2.copy()
# del d3["roshan"]
# d2.update({"leena": "toffee"})
# print(d2.keys())
# print(d2.values())
#
# dc = {"mutable": "Which can be change",
# "immutable": "Which cannot be changed",
# "tuple": "A function which cannot be changed",
# "list": "A function which can be changed",
# "help": "kisi ki madad karna",
# "suggest" : "sujhav dena"}
# n1 = input("Enter your word\n")
# print("your words meaning is : " + dc[n1])
# dictio = {'dictionary':'this is a data type','python':'this is a programming language',
# 'santosh':'he is a boy','gupta':'it is a surname'}
# word = input("Enter The Word\n")
# print("definition is : " + dictio[word])
# set
# s = set()
# s1 = [1, 2 , 3 , 4 , 5 , 6]
# s_from_list = set(s1)
# print(s_from_list)
# s.add(2)
# s.add(4)
# s1 = {1,2,3,4}
# print(s.isdisjoint(s1))
Comments
Post a Comment