Tutorial


Home
Members
Schedule
Project
Tutorial
Contact Information SourceForge.net Logo

  • Requirements

1- Install latest  jdk

http://java.sun.com/javase/downloads/index.jsp


2- Update system variable path by adding jdk path
For example (C:\Program Files\Java\jdk1.6.0_01\bin)
 

-right click on my computer --> properties --->Advanced ---> Environment Variables
- from "system variable" choose path
-click edit
- add at the end of variable value the string
"; C:\Program Files\Java\jdk1.6.0_01\bin"
-click ok

3- If there are more than one java runtime remove all except the latest one

4- CHECK CONTROL_PANEL -> REGIONAL AND LANGUAGES -> ADVANCED -> LANGUAGE FOR NON-UNICODE
IT SHOULD BE YOUR LOCALL LANGUAGE
 

  • Adding a language

For adding your language to upl; you may follow those steps:


1. make a copy of an existing language, for example the file "English.txt"
2. rename it to any name, let it example.txt
3. translate the text to your new language

Note:

* keywords and value types MUST Not has any white space
(newline) can be changed to (new_line) but NOT (new line)

* in the file:
0 means that your language is left to right language (English like)
1 means that your language is right to left language (Arabic like)
 

* keywords are:

declare,print,newline,read,do,int,double,string,if,end_if,else,

loop_if,end_loop,at,from,to,join
 

  • Decleration

declare is used to define a variable

three types of variables are available (int,double,string)

a declared variable MUST has an initial value

examples:

declare int example =0

declare double example =0.5

declare string example ="text"

  • Print

print is used to print a variable or text

it can print ONLY one variable or text at a time

examples:

print example

print "text"

 

  • Read

read is used to read a value for a variable

it can read ONLY one value at a time

examples:

       read example

 

  • NewLine

      newline is used to add a new line to the output

      examples:

               newline

 

  • Do

             do is used to manipulate the variables

             what it can do is depending on the variable type

              examples:

                        variable type int:

                            do example = 5

                            do example = example

                            do example = example + example

                            do example = example + 5

                            do example = 5 + example

                            // + can be replaced by - * / %

 

                        variable type double:

                            do example = 5.5

                            do example = example

                            do example = example + example

                            do example = example + 5.5

                            do example = 5.5 + example

                            // + can be replaced by - * / %

 

                        variable type string:

                            do example = "text"

                            do example = example

                            do example = example join example

                            do example = example join  "text"

                            do example = "text" join example

                            do example =  "text" join  "text"

                            do example = example at 1

                            do example = example from 0 to 4

 

  • if else end_if

             if conditions are the same for both string, int and double variables

             they are = > < >= <= !=

              examples:

                    if example1>example2

                        //statments

                    else

                        //statments

                    end_if

///////////////////////////////////////////////////////////

                    if example1>5

                        //statments

                    else

                    if example1>example2

                        //statments

                    else

                        //statments

                    end_if

                        //statments

                    end_if

///////////////////////////////////////////////////////////

                    if example1>"text"

                        //statments

                    end_if

 

  • loop_if end_loop

declare int count=0

loop_if count < 10

print count

do count=count+1

end_loop


Home | Members | Schedule | Project | Tutorial | Contact Information

 Copyrighted 2007-2008 AL-YAMANI .
For problems or questions regarding this Web site contact Ahmed AL-Yamani.
Last updated: 06/21/08.