I would like to understand what does the expression p: dict = {} mean. To me it is not as intuitive as p = {}. Why does the part : dict add to the expression? To me it appears to not add anything at all.
The code I am looking at is as follows
>>> p = {}
>>> p['s'] = 2
>>> p
{'s': 2}
>>> p: dict = {}
>>> p['a'] = 4
>>> p
{'a': 4}
 
     
    