FizzBuzz, as explained in this Wikipedia article, or this YouTube video, is often used as a technical interview question when recruiting programmers.
The goal is usually to write a short program, which prints out the numbers 1 to 100, but if the number is divisible by 3, then to print "Fizz" instead of the number. If it is divisible by 5 then "Buzz" should be printed. If the number is divisible by both 3 and 5 then "FizzBuzz" is printed.
Well, firstly, let's explain what it's not. It is not a language to make writing FizzBuzz easier. Oh no,
that would be too useful! Instead, FizzBuzzLang is an esoteric programming
language which uses just three keywords: FIZZ
, BUZZ
and FIZZBUZZ
. So, if anything, it makes writing the FizzBuzz challenge a whole lot more difficult.
FizzBuzzLang is a Turing-complete language that, if you are patient (or crazy) enough, can be used to write complex(ish) programs.
Here is a Hello World implementation in FizzBuzz:
See! Only 31 lines (excluding comments).
As the README.md file for the project says: it is firmly believed that most esoteric programming languages are the result of the affect of alcohol on the brains of carbon-based life forms. FizzBuzzLang is no different!
The main reason for creation was in the hope that a tech interview sometime, somewhere would go like this:
Interviewer: Ok, can you write FizzBuzz for us?
Dev: Sure, what do you want me to write?
Interviewer: Ummmm…FizzBuzz?
Dev: Yes, but what? Hello World? An I/O example?
Interviewer: ...(look of confusion creeps across their face)
The author admits that it might never happen, but (along with the alcohol he was drinking) it was enough to amuse him.
Well, first - steady on. No one has ever called it miraculous. Pointless, yes. Miraculous? That's a stretch!
All of the details are in the GitHub repository.
If it completely Nerd Snipes you, then feel free to fork the project and add to the specification or the interpreter.
Happy FizzBuzzing!
© Matt Rudge, 2019-2020. FizzBuzzLang is released under the Gnu Public License (GPL) version 3.