Bhai-Lang is a new funny Indian programming language, written in Typescript by two Indian engineers. In Indian slang, Bhai means brother or bro, and the whole conversation is used by this type of funny accent and that’s the reason it is easy to understand.
Either you can use this Bhai-language via “bhailang – npm” or directly run on their live coding playground.
Bhai-Lang: Starts and Ends with
The program starts with ?’hi bhai’ and ends with ‘bye bhai’ everything outside of this will be ignored.
hi bhai
// Write code here
bye bhai
Bhai-Lang: Variables
In Bhai_Lang variables is declared using “Bhai ye hai”
hi bhai
bhai ye hai a = 10;
bhai ye hai b = "two";
bhai ye hai c = 15;
a = a + 1;
b = 21;
c *= 2;
bye bhai
SEE ALSO: New Technology Trends For 2022
Bhai-Lang: Types
Numbers and strings are like other languages. Null values can be denoted using nalla
. sahi
and galat
are the boolean values.
In this programming language if you want to give value null to any variable you can use “nalla”,
for boolean values like “sahi” for true, “galat” for false.
hi bhai
bhai ye hai e = nalla;
bhai ye hai f = sahi;
bhai ye hai g = galat;
bye bhai
“bol bhai” is used to print something on the console
Bhai-Lang: Conditionals
Bhailang supports simple if else construct , agar bhai
block will execute if the condition is sahi
and warna bhai
block will execute if condition is galat
.
hi bhai
bhai ye hai a = 10;
agar bhai (a < 25) {
bol bhai "a is less than 25";
} warna bhai {
bol bhai "a is greater than or equal to 25";
}
bye bhai
Bhai-Lang: “Bhai kya kar raha hai tu”
if your code runs successfully this programming language gives “?Shandar Bhai” message in green color as output
but for error, you see Ashneer Grover Famous message “Bhai kya kar raha hai tu” with red text.
Here is the open-source GitHub repo of this ‘Bhai-Lang’ you can see whole language directory loops, programming conditions also contribute more to adding your own funny Hindi coding keywords for further improvement.
BhaiLang Creators
Amazing language with two amazing Indian developers! Rishabh and Aniket both are from India Bhopal, Madhya Pradesh. Rishabh is working with Grow and Aniket with Amazon.
*Source: ProgrammerJokes.Com