Why do you assign Temp to Input, leading to a cycle of only 1