i have few variables like this:
self.lamp_1
self.lamp_2
self.lamp_3
self.lamp_4
and now i want to use each of this names is loop to call them automaticly, like this:
for i in range(1,5):
self.canvas.itemconfig(self.lamp_/number_i_automaticly/, fill=self.color_blink)
I tried using function eval() but it doesn't work. It stops running my program.
eval("self.canvas.itemconfig(self.lamp_"+str(i)+",fill=self.color_blink)")
how can i declerate names of variables in that way, using key i?