Category:XBS

From Rosetta Code
Revision as of 02:22, 2 September 2021 by rosettacode>FIREYAUTO
This page is a stub. It needs more information! You can help Rosetta Code by filling it in!
Language
XBS
This programming language may be used to instruct a computer to perform a task.
See Also:


Listed below are all of the tasks on Rosetta Code which have been solved using XBS.

What is XBS?

XBS is an interpreted language written in JavaScript. The main purpose of XBS is to provide an easy way to interact with the web.


Details

XBS has a github page and is currently open-sourced. The github page has a wiki for the documentation; but just know, this language still isn't done. It has most features a programming language has, except for some minor details that I need to fix.

XBS is still under active development, and gets updates/bug fixes almost everyday.


Code Examples

Variable declaration

<lang xbs>set x = "Hello, world!"; log(x)</lang>

Functions

<lang xbs>func FirstFunction(a,b){

   send a+b; #Add a and b

} log(FirstFunction(1,2));</lang>

Typed XBS

XBS has another version which is typed, and has improved features. Typed XBS allows better function defaults, variable types, function return types, function parameter types, improved expressional parsing, custom datatype methods, and some other features. Currently, typed XBS is implemented in the XBS Code Editor, which can be found in the links category. <lang xbs>func Add(a:number=1,b:number=2):number{ send a+b; #Add a & b }

log(Add(2,2)); log(Add());</lang>

<lang xbs>set String = "Hello, world!"; log(String::reverse())</lang>


Links

Github
XBS Code Editor

Notes

The XBS code editor uses a different version of XBS. To see more into details, the code editor explains it on the page.