Juliar.Future: Guide to building a simple program

January 26, 2017 | Views: 2700

Begin Learning Cyber Security for FREE Now!

FREE REGISTRATIONAlready a Member Login Here

Estimated reading time: 1 minute

Hey guys,

Today we will be learning to program something in Juliar.Future (j.F)

j.F allows the use of prefix notation, that means      + 3 2 is equivalent to 3+2. This is useful in Juliar as it allows you to call + on every element. It makes sense to use it on a data i.e. when loading a file, you could add the numbers up without manipulating data i.e. 32.0 55 22 77 etc.

j.F also follows open system standards and to do system operations at the system API level.

Here is the code that we will look at:

function main() = {
    printLine(" ============= main method ================");


    int z1 = - 58912 2;
    int X1 = - 3 2;


    printLine("printing the value of the z1 variable");
    printInt(z1);


    call test();


    printLine ("=========== end of main method==================");
}




function test() = {
    printLine("======= test method===============");
    int s = - 1259 2;
    printInt( s );
    printLine("=======end of test method==========");
}

printLine basically outputs the content to the file or terminal.

printInt converts everything to numbers and output numbers. So, if you have “A” it will output 65.

 

The main() is called when code enters the script. Please NOTE: This ONLY occurs if it is the main file. If the file is loaded from another function, it will not be called.

Here we use the call method to call function test(). However, you will be able to just use test() in the near future. The call method will be deprecated soon.

I wish you luck!


For the latest news visit https://www.juliar.org, and the forums at https://www.juliar.org/forums.

Share with Friends
FacebookTwitterLinkedInEmail
Use Cybytes and
Tip the Author!
Join
Share with Friends
FacebookTwitterLinkedInEmail
Ready to share your knowledge and expertise?
Comment on This

You must be logged in to post a comment.

Our Revolution

We believe Cyber Security training should be free, for everyone, FOREVER. Everyone, everywhere, deserves the OPPORTUNITY to learn, begin and grow a career in this fascinating field. Therefore, Cybrary is a free community where people, companies and training come together to give everyone the ability to collaborate in an open source way that is revolutionizing the cyber security educational experience.

Cybrary On The Go

Get the Cybrary app for Android for online and offline viewing of our lessons.

Get it on Google Play
 

Support Cybrary

Donate Here to Get This Month's Donor Badge

 
Skip to toolbar

We recommend always using caution when following any link

Are you sure you want to continue?

Continue
Cancel