in reply to simple array question
The author of the book is obviously demonstrating how to use an array, since he defines @compass with a beginning "@".
Arrays are declared with round brackets, so replace the curled brackets with round brackets, and the program will be functional.