def handle_command(command):
try:<EOL><INDENT>cmds = command.split(None, <NUM_LIT:1>)<EOL>cmd = cmds[<NUM_LIT:0>]<EOL>if cmd == '<STR_LIT>':<EOL><INDENT>add_task(get_arg(cmds))<EOL><DEDENT>elif cmd == '<STR_LIT>':<EOL><INDENT>mark_done(int(get_arg(cmds)))<EOL><DEDENT>elif cmd == '<STR_LIT:list>':<EOL><INDENT>for task in format_tasks(list_tasks()):<EOL><INDENT>print(task)<EOL><DEDENT><DEDENT>elif cmd == '<STR_LIT>':<EOL><INDENT>delete_task(int(get_arg(cmds)))<EOL><DEDENT>else:<EOL><INDENT>print_usage()<EOL><DEDENT><DEDENT>except Exception as e:  <EOL><INDENT>print(e)<EOL>print_usage()<EOL><DEDENT>
Accepts a string command and performs an action.

    Args:
      command: the command to run as a string.