qalam 0.3.1

Interpreter for the Qalam programming language. Qalam is a dead-simple, Urdu inspired, interpreted programming langauge.
Documentation

bolo "clock()";
// prints the time since the epoch in seconds
bolo clock();
bolo "";

bolo "pow(3, 2)";
// Prints 3^2 = 9
bolo pow(3, 2);
bolo "";

rakho a = 2;
rakho b = 3;

bolo "max(2, 3)";
// Prints 3
bolo max(a, b);
bolo "";

bolo "min(2, 3)";
// Prints 2
bolo min(a, b);
bolo "";

bolo "len(my_name)";
rakho my_name = "Ammar";
// Prints 5
bolo len(my_name);
bolo "";

rakho num_str = "-1";
// Prints 0 (-1 + 1) 
// str2num("hello") would throw an error
bolo "str2num(-1) + 1";
bolo str2num(num_str) + 1;
bolo "";

bolo "converting different types to string";
// Prints sach jhoot khali 12.34
bolo(str(sach) + " " + str(jhoot) + " " + str(khali) + " " + str(12.34));
bolo "";

bolo "typeof various types";
// Prints string
bolo typeof("hello world");
// Prints number
bolo typeof(123);
// Prints bool
bolo typeof(jhoot);
// Prints amal
bolo typeof(typeof);
// Prints khali
bolo typeof(khali);
bolo "";

rakho name = "Ammar Ahmed";
rakho first = substr(name, 0, 5);
rakho last = substr(name, 6, 5);
bolo "substring of Ammar Ahmed";
// Prints "Ammar"
bolo first;
// Prints "Ahmed"
bolo last;
bolo "";

bolo "iterating over string";
// We can also use the substr and len methods to iterate over a string
har(rakho i = 0; i < len(name); i = i + 1) {
  // Prints each character of name
  bolo str(i) + ": " + substr(name, i, 1);
}
bolo "";

bolo "searching for position of substring: 'Ahmed' in 'Ammar Ahmed'";
bolo index_of(name, last);
bolo "";

bolo "searching for position of substring: 'Hello' in 'Ammar Ahmed'";
bolo index_of(name, "Hello");
bolo "";

bolo "replacing substring 'Ammar' with 'Saniya' in 'Ammar Ahmed'";
bolo replace(name, "Ammar", "Saniya");
bolo "";

bolo "replacing substring 'Hello' with 'Saniya' in 'Ammar Ahmed' (doesn't do anything)";
bolo replace(name, "Hello", "Saniya");
bolo "";

bolo "generate a random number between -12.3 to 14.5";
bolo random(-12.3, 14.5);
bolo "";

bolo "genterate a random integer between -13 to 15";
bolo random_int(-13, 15);
bolo "";