BUTTON(number) returns the button code. It's a binary value, with bits corresponding to buttons. 1 for up 2 for down 4 for left 8 for right 16 for A 32 for B etc... But SmileBASIC also includes constants such as #UP, #DOWN, #A, and #L that store these button codes, so you don't have to memorize them if you don't want to.