print function declarations before definitions
get rid of dollars in variable names