Why the words outside the main loop won't work?