MIllis , int not refresh value

When I check the value " int " on the serial monitor everything changes correctly, but it looks like they are not loaded into periods[] they stay with the value that was at the start of the program.

Just because the periods[] array is initialised with values from variables does not mean that if you change the values of the variables that the values stored in the array will change.

You need to explicitly change the values in the array from user input in order to change the LED periods.