Here is an exercise on dictionaries for you.
The first question is on dictionary comprehension.
You need to define a dictionary in which the keys are numbered from 1 to 5 whereas the values in the
dictionary is a square all the corresponding key and this is the expected output.
The key and value pairs key and value pairs.
The next question is on dictionary method.
You need to define a dictionary stored in dict 1 and these are the key value pairs in this dictionary.
Next you need to define another empty dictionary student underscored to do next.
Each key value pair from student dict one should be copied to student to do so for example after you
copy this key value pair from student dict 1 to student to do this key value pair needs to be deleted
from student dict 1 and then you go to the next e value paired in student dict 1.
Say for example the next key value pair the two copy is this key value pair from student dict 1 to Student
2 after copying this key value pair.
This needs to be deleted from student dict 1 So this action needs to be performing until all items are
copied from stored in dict 1 to student to do and only STUDENT 1 should be an empty dictionary and this
is the expected output and you can make use of the different methods that were discussed in the class
who write by then program.