<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def add_str(window, line_num, str):
 """ attempt to draw str on screen and ignore errors if they occur """

    try:
        window.addstr(line_num, 0, str)
    except curses.error:
        pass