title: Curses in Python2.7.10 / 3.4.3 addstr() error
body: <p>I am testing out the curses module for python and I encountered this error while trying a simple script:</p>
  
  <blockquote>
    <p>NameError: global name 'addstr' is not defined</p>
  </blockquote>
  
  <p>Here is my code:</p>
  
  <pre><code>#!/usr/bin/env python
  
  import curses, sys
  from curses import *
  
  def main():
  
      stdscr = initscr()
  
      addstr("Hello")
  
      endwin()
  
  if __name__ == "__main__":
      main()
  </code></pre>
  
  <p>I don't know what Newbie mistake I made, I am following a guide for curses on python.
  Thanks in advance.</p>