You could use the walrus operator in a dictionary value as follows:
count = 10
dictionary1 = {
1: 'One', 2: 'Two', 3: (count := count + 1)
}
print(dictionary1[3])
The walrus operator returns the value of the assignment.