title: `if __name__ == '__main__'` equivalent in Ruby
body: <p>I am new to Ruby.  I'm looking to import functions from a module that contains a tool I want to continue using separately.  In Python I would simply do this:</p>
  
  <pre><code>def a():
      ...
  def b():
      ...
  if __name__ == '__main__':
      a()
      b()
  </code></pre>
  
  <p>This allows me to run the program or import it as a module to use <code>a()</code> and/or <code>b()</code> separately.  What's the equivalent paradigm in Ruby?</p>