2.1. Hello Felix

There is no better introduction to a programming language than the infamous hello world program
Start felix section to tut/tutorial/tut-1.01-0.flx[1 /1 ]
     1: #line 32 "./lpsrc/flx_tutorial.pak"
     2: #import <flx.flxh>
     3: print "Hello World\n";
End felix section to tut/tutorial/tut-1.01-0.flx[1]
Start data section to tut/tutorial/tut-1.01-0.expect[1 /1 ]
     1: Hello World
End data section to tut/tutorial/tut-1.01-0.expect[1]
and the Felix version is simplicity itself. The first line includes the standard library, and the second prints the hello world message. You'll notice that the argument to print is not enclosed in brackets. We'll learn more about this shortly.

To run the example, make sure you are in the directory containing the Felix demo package, then type:

  bin/flx tut/tutorial/tut-1.01
This produces three files:
  tut/tutorial/tut-1.01.hpp  tut/tutorial/tut-1.01.cpp  tut/tutorial/tut-1.01.so
We'll learn more about their structure later.