48 lines
985 B
Plaintext
48 lines
985 B
Plaintext
--- Heyo
|
|
|
|
type boolean (false, true)
|
|
|
|
type character = -128 .. 127;
|
|
type integer = -2000000000 .. 2000000000;
|
|
type natural % 2000000000;
|
|
|
|
type structure:
|
|
integer a = 0;
|
|
boolean b = 0;
|
|
natural c = 0;;
|
|
|
|
type system_call (
|
|
linux_read_system_call = 0,
|
|
linux_write_system_call = 1,
|
|
linux_open_system_call = 2,
|
|
linux_close_system_call = 3,
|
|
linux_exit_system_call = 60)
|
|
|
|
type file_descriptor (
|
|
standard_input = 0,
|
|
standard_output = 1)
|
|
|
|
main:
|
|
x: integer = 1;
|
|
loop (x++ < 101):
|
|
if ((x % 3 = 0) && (x % 5 = 0))
|
|
echo ("fizzbuzz\n");
|
|
else if (x % 3 = 0):
|
|
echo ("fizz\n");
|
|
echo ("and again fizz\n");;
|
|
else if (x % 5 = 0)
|
|
echo ("buzz\n");
|
|
else:
|
|
echo ("fuck formatting...\n");
|
|
echo ("fuck formatting twice...\n");;
|
|
return (0);;
|
|
|
|
string_length (character * text):
|
|
length: natural = 0;
|
|
loop (* (text + length++));
|
|
return (length);;
|
|
|
|
echo (character * text):
|
|
system (linux_write_system_call, standard_output, text, string_length (text));
|
|
return;;
|