getting code to work