I am not sure why, but for some reason when I execute the code it says that the length of the array right is undefined, but why is right undefined? In the execution of this code