Return to basics – First steps

Once you have return to basics installed it is time to start programming,  you can look at some of the example programs. (see Gordons Website for how to do this – li  basically its the wget command.

Note files will be saved in the directory from which you issued the rtb command so you may want to

mkdir rtbasic

cd rtbasic

so all files are saved to the rtbasic directory.

Due to the way I have organised things on my file system I am saving to :

~/Documents/programming/rtbasic$

so start by launching return to basics (which from now on will be written as rtb)

return-to-basics1

From here we have access to the prompt but there is a nice built in editor we can use too.  To get to this press F2

rt-editor

So from here we can type our first program,  however before we do that lets have a quick look at the first help screen as this has a few useful commands on it.

press F1

rtb-help

Ok now we know how to move around the program,  press ESCape to get back to the interpreter

YOUR FIRST PROGRAM

in the editor type

Press F5 and give it a useful file name e.g hello

this will SAVE the program

Press F3 to run

Ok this should just print “HELLO, WORLD” on the screen

If this works we can try and make it a little more interesting

FOR X = 1 TO 20 CYCLE
PRINT "HELLO, WORLD"
REPEAT
STOP

Save F5 and run F3

This should print “HELLO, WORLD” about 20 times.

rtb-firstprogrun