#get the key of a minimum value from a given dictionary
dict1={"physics":82,"math":65,"history":75}
mini=min(dict1.values())
for i in dict1:
if dict1[i]==mini:
j=i
print(j)
math
#check if 200 value is present in the dictionary
dict1={"a":100,"b":200,"c":300}
for i in dict1:
if dict1[i]==200:
x=True
break
else:
x=False
if x==True:
print("200 is present in the dictionary.")
if x==False:
print("200 is not present in the dictionary.")
200 is present in the dictionary.
#merging 2 dictionaries into one
dict1={"ten":10,"twenty":20,"thirty":30}
dict2={"thirty":30,"forty":40,"fifty":50}
for i in dict2:
dict1[i]=dict2[i]
print(dict1)
{'ten': 10, 'twenty': 20, 'thirty': 30, 'forty': 40, 'fifty': 50}