code for printing commands