Yabasic
   HOME

TheInfoList



OR:

Yabasic (Yet Another BASIC) is a free,
open-source Open source is source code that is made freely available for possible modification and redistribution. Products include permission to use and view the source code, design documents, or content of the product. The open source model is a decentrali ...
BASIC Basic or BASIC may refer to: Science and technology * BASIC, a computer programming language * Basic (chemistry), having the properties of a base * Basic access authentication, in HTTP Entertainment * Basic (film), ''Basic'' (film), a 2003 film ...
interpreter Interpreting is translation from a spoken or signed language into another language, usually in real time to facilitate live communication. It is distinguished from the translation of a written text, which can be more deliberative and make use o ...
for
Microsoft Windows Windows is a Product lining, product line of Proprietary software, proprietary graphical user interface, graphical operating systems developed and marketed by Microsoft. It is grouped into families and subfamilies that cater to particular sec ...
and
Unix Unix (, ; trademarked as UNIX) is a family of multitasking, multi-user computer operating systems that derive from the original AT&T Unix, whose development started in 1969 at the Bell Labs research center by Ken Thompson, Dennis Ritchie, a ...
platforms. Yabasic was originally developed by Marc-Oliver Ihm, who released the last stable version 2.91.2 in 2025. From version 2.77.1, the project has adopted the
MIT License The MIT License is a permissive software license originating at the Massachusetts Institute of Technology (MIT) in the late 1980s. As a permissive license, it puts very few restrictions on reuse and therefore has high license compatibility. Unl ...
as well as the source code being moved to
GitHub GitHub () is a Proprietary software, proprietary developer platform that allows developers to create, store, manage, and share their code. It uses Git to provide distributed version control and GitHub itself provides access control, bug trackin ...
to encourage others to participate in its development.


Features

* No compulsory line numbers (they can be used but are optional) * Line graphics in color *
Structured programming Structured programming is a programming paradigm aimed at improving the clarity, quality, and development time of a computer program by making specific disciplined use of the structured control flow constructs of selection ( if/then/else) and repet ...
—various block structures, named
subroutines In computer programming, a function (also procedure, method, subroutine, routine, or subprogram) is a callable unit of software logic that has a well-defined interface and behavior and can be invoked multiple times. Callable units provide a p ...
with local variables and return values * Code modules/
libraries A library is a collection of Book, books, and possibly other Document, materials and Media (communication), media, that is accessible for use by its members and members of allied institutions. Libraries provide physical (hard copies) or electron ...
with separate
namespaces In computing, a namespace is a set of signs (''names'') that are used to identify and refer to objects of various kinds. A namespace ensures that all of a given set of objects have unique names so that they can be easily identified. Namespaces ...
(On the other hand, composite data structures are missing) * Option to use a
graphical user interface A graphical user interface, or GUI, is a form of user interface that allows user (computing), users to human–computer interaction, interact with electronic devices through Graphics, graphical icon (computing), icons and visual indicators such ...
based on the
GTK GTK (formerly GIMP ToolKit and GTK+) is a free software cross-platform widget toolkit for creating graphical user interfaces (GUIs). It is licensed under the terms of the GNU Lesser General Public License, allowing both Free software, free and ...
library *
Self-modifying code In computer science, self-modifying code (SMC or SMoC) is source code, code that alters its own instruction (computer science), instructions while it is execution (computing), executing – usually to reduce the instruction path length and imp ...
* "Binding" a Yabasic program to the interpreter, creating a standalone
executable In computer science, executable code, an executable file, or an executable program, sometimes simply referred to as an executable or binary, causes a computer "to perform indicated tasks according to encoded instruction (computer science), in ...
in a single file


Other versions


Yab

A version optimized for
BeOS BeOS is a discontinued operating system for personal computers that was developed by Be Inc. It was conceived for the company's BeBox personal computer which was released in 1995. BeOS was designed for multitasking, multithreading, and a graph ...
,
ZETA Zeta (, ; uppercase Ζ, lowercase ζ; , , classical or ''zē̂ta''; ''zíta'') is the sixth letter of the Greek alphabet. In the system of Greek numerals, it has a value of 7. It was derived from the Phoenician alphabet, Phoenician letter zay ...
and
Haiku is a type of short form poetry that originated in Japan. Traditional Japanese haiku consist of three phrases composed of 17 Mora (linguistics), morae (called ''On (Japanese prosody), on'' in Japanese) in a 5, 7, 5 pattern; that include a ''kire ...
.


Flyab

A port of Yabasic to the Fltk toolkit called "Flyab" was under development. It would have been source-compatible with programs written in yab, a variant of Yabasic that enables graphical programs to be written using the
BeOS BeOS is a discontinued operating system for personal computers that was developed by Be Inc. It was conceived for the company's BeBox personal computer which was released in 1995. BeOS was designed for multitasking, multithreading, and a graph ...
API An application programming interface (API) is a connection between computers or between computer programs. It is a type of software interface, offering a service to other pieces of software. A document or standard that describes how to build ...
. After
BeOS BeOS is a discontinued operating system for personal computers that was developed by Be Inc. It was conceived for the company's BeBox personal computer which was released in 1995. BeOS was designed for multitasking, multithreading, and a graph ...
and its successor
ZETA Zeta (, ; uppercase Ζ, lowercase ζ; , , classical or ''zē̂ta''; ''zíta'') is the sixth letter of the Greek alphabet. In the system of Greek numerals, it has a value of 7. It was derived from the Phoenician alphabet, Phoenician letter zay ...
finally were gone, the team members around yab for BeOS decided to move to Linux and therefore chose FLTK to implement the UI parts. Ports for Microsoft Windows,
Mac OS X macOS, previously OS X and originally Mac OS X, is a Unix, Unix-based operating system developed and marketed by Apple Inc., Apple since 2001. It is the current operating system for Apple's Mac (computer), Mac computers. With ...
, and Linux would have been possible. Flyab added the ability to Yabasic to create native graphical user interfaces on all supported platforms. Main difficulty was to fully implement the layout commands to FLTK, as used from the BeOS version. As of November 2008, the project appears to be halted.


PlayStation 2

Sony also packaged a version of Yabasic for the
PlayStation 2 The PlayStation 2 (PS2) is a home video game console developed and marketed by Sony Interactive Entertainment, Sony Computer Entertainment. It was first released in Japan on 4 March 2000, in North America on 26 October, in Europe on 24 Novembe ...
on the demo discArchived a
Ghostarchive
and th
Wayback Machine
shipped with PS2 consoles in PAL territories so it could be considered a home computer, not just a games machine, thus bypassing European import taxes.


Yabasic 3.0 (Unofficial)

As a continuation of the project prior to new changes by the original author, version 3 was being developed by a team centered on Pedro Sá and Thomas Larsen, but development has halted and the project now appears to be abandoned.


Yabasic example

#!/usr/bin/yabasic REM Program Name: cbm-mtudemo.yab REM Author: mtu REM REM Purpose: demonstration for their CBM-PET graphics card 320x200 open window 320, 200 20 P=160: Q=100 30 XP=144: XR=1.5*3.1415927 40 YP=56: YR=1: ZP=64 50 XF=XR/XP: YF=YP/YR: ZF=XR/ZP 60 FOR ZI=-Q TO Q-l 70 IF ZI<-ZP OR ZI>ZP GOTO 150 80 ZT=ZI*XP/ZP: ZZ=ZI 90 XL=INT(0.5+SQRT(XP*XP-ZT*ZT)) 100 FOR XI=-XL TO XL 110 XT=SQRT(XI*XI+ZT*ZT)*XF: XX=XI 120 YY=(SIN(XT)+0.4*SIN(3.0*XT))*YF 130 GOSUB 170 140 NEXT XI 150 NEXT ZI 160 PAUSE 10 END 170 X1=XX+ZZ+P 180 Y1=YY-ZZ+Q:Y1=199-Y1 190 LINE X1,Y1,X1,Y1-1 200 IF Y1=0 GOTO 220 210 CLEAR LINE X1,Y1+1,X1,199 220 RETURN


References


External links

* — Downloads and documentation for Yabasic 2.90.2
Yabasic GitHub
— Source code for Yabasic on GitHub. {{BASIC Articles with example BASIC code BASIC interpreters BASIC programming language family Software using the MIT license Free and open source interpreters Procedural programming languages Linux programming tools Programming tools for Windows Programming languages created in 1995