3 Python Challenges ||Dictionaries in Python

python_challenge

Python Challenge 1

There is a dictionary d1, Check if the dictionary has that key then print the key and value of that dictionary.

Example: d1={‘abc’:’123′,’bcd’:’234′,’ace’:’213′,’def’:’2341′}

key to found ‘abc’


import requests

Python Challenge 2

You have marks of students in a dictionary where keys are Names of students and values are their marks. Print dictionary of students whose marks are greater than 180.


Wait

Python Challenge 3

You have two dictionaries ,print keys which are in both dictionaries along with their values.


wait

Solutions will be updated tomorrow . If you are able to solve the challenge comment below.

1 Trackback / Pingback

  1. Python interview questions on data types - Language Forest

Leave a Reply

Your email address will not be published.


*