python type hints Dict code example
Example: dict typing python
from typing import dict
my_dict :dict[key_type, value_type] ={}
# Exemple:
dict1 :dict[str, int] = {
"zero" : 0,
"one" : 1,
"two" : 3
}
from typing import dict
my_dict :dict[key_type, value_type] ={}
# Exemple:
dict1 :dict[str, int] = {
"zero" : 0,
"one" : 1,
"two" : 3
}