Fast Track 1.1: Difference between revisions

From BR Wiki
Jump to navigation Jump to search
 
(2 intermediate revisions by the same user not shown)
Line 40: Line 40:


====Write a classic program:====
====Write a classic program:====
Note that BR uses line numbers. It is recommended that you use an external editor and BR compiler to get around this once you're comfortable with the basics.


  10 print “hello world”  
  10 print “hello world”  
 
  RUN  
  RUN  


Line 50: Line 51:


will save your program, naming it "hello".
will save your program, naming it "hello".
<noinclude>
[[Category:Fast Track Tutorial]]
</noinclude

Latest revision as of 21:00, 5 August 2014

Basics

BR is an object oriented programming language, with the goal of quickly creating customized business software that is efficient, powerful, and easy to use.

PRINT

The basic command, print, will print anything back onto your console (hit enter after typing each line).

PRINT 10 +6
PRINT “Here we go!”
PRINT variable$
PRINT NumericExpression

LET

LET will set the value of a variable. Non-numeric, or string variables, always end in $, and the assigned data must always have quotes around it.

LET string$=”Print it all.”

PRINT string$ 

will return

Print it all.

That's a string, or non-numeric variable. A numeric variable NUMVAR

Let numvar=10
Let numvar2=20
Print numvar+numvar2

will return

30

Print environmental variables:

PRINT version$

will return the version of BR that you are using.


Write a classic program:

Note that BR uses line numbers. It is recommended that you use an external editor and BR compiler to get around this once you're comfortable with the basics.

10 print “hello world” 

RUN 

will run your program.

SAVE hello

will save your program, naming it "hello". </noinclude