Trouble spawning objects at a random location along an axis

Thanks a lot this helped a bunch, got really confused when trying to make it and now I can get on with it. Thanks again.