Coding Lab | Nurturing Future Leaders in Technology

View Original

3 Fun (Programming) Facts for the Year of the Ox

Happy Lunar 牛 ('niu' pronounced as 'new', it means cow/ox) Year! For all of our Chinese friends, this year is the Year of the Ox, and 12th February 2021 marks the start of the Chinese New Year on the traditional lunar calendar – which lasts for 15 days. In line with this event, did you know that there are ox and cow -related programming languages?

This year's festivities are a little different as we spend our long weekend at home staying safe. We share some fun (programming) facts related to the Year of the Ox to keep you occupied, and perhaps to inspire you to code your next program! Here they are:

1. Cow Programming Language

Considered one of the Top 5 Hardest Programming Languages in the world, it has 12 instructions that vary on the capitalisations of "moo", such as "Moo" and "mOo" and with the exceptions of MMM, OOO, oom and OOM. Created in 2003 by Sean Heber, it is an esoteric programming language (often shortened to "esolang") - this means that it is a programming language built as a joke and to explore the theory of computation, not for solving computational, practical problems.

You'll see what we mean with this example, which translates to "Hello" in Cow programming language:

3 Fun (Programming) Facts for the Year of the Ox - Cow Programming Language

We're not joking!

2. Ox Programming Language

3 Fun (Programming) Facts for the Year of the Ox - Ox Programming Language

This object-oriented matrix programming language is used academically in econometrics and statistics (it is also available for non-academic use!). Developed by Jurgen Doornik, it has a comprehensive mathematical and statistical function library and syntax similar to C++, which has resulted in faster and more efficient programs that are easier to maintain.

See this content in the original post

Get a glimpse of the OxMetrics interface

Ox programming language uses OxMetrics to produce graphics and reports, which assists in econometrics and statistical modelling, as well as financial analysis. It is a powerful tool that enables users to write their own programs, plot graphs, and so much more – and is great for people with basic programming language too!

3. Cows and Bulls

3 Fun (Programming) Facts for the Year of the Ox - Bulls and Cows

Even if you've never heard of this, the concept behind this game will definitely be familiar! Remember the game Mastermind? You create a secret 4-digit code, and the other player tries to guess it within a number of tries. You get a bull point if you get the correct digit and correct position, and a cow point if you get the correct digit, but in the wrong position. This feedback helps in logically guessing the secret code.

See this content in the original post

The game Mastermind

One of the first computer implementations for this game was created in 1970 – a program simply called "moo" – written by J.M. Grochow at MIT for the Multics operating system. Today, you can play this Cows and Bulls (also known as Bulls and Cows) game against computers too!

For all coders out there, you can even try programming this yourself too. Find the tasks here, and solve it in your preferred programming language. This may not be programming-related, but it sure is code-breaking!

Bonus: The Great Race of the Zodiac Animals

In the festivities of Chinese New Year, what would this post be without a fun fact of the zodiac year? Did you know that the Ox is second among the 12 Chinese zodiac animals - after the rat? Legend has it that there was a Great Race to cross the river to derive at this sequence. The Rat jumped on the Ox as it made its way across the river, then the Rat proceeded to jump across the finish line to win, while the Ox ranked second place.

See this content in the original post

The remaining animals placed in the following order: Tiger, Rabbit, Dragon, Snake, Horse, Goat, Monkey, Rooster, Dog, then Pig.

Coding Lab wishes you a Happy Lunar Niu/New Year!

The Coding Lab team wishes everyone a prosperous Lunar New Year! :)

You now know some cool fun facts and learnt a little more about programming too. We hope that we've also inspired your next coding program, and don't forget to share these facts with your friends!

(Written by Cheryl Tang)

Hop on board the Coding Lab train! Click here to get our monthly newsletters straight to your inbox.

Header image for Brain Foods blogpost

Food For Thought: Best Brain Food for Programmers

The Straits Times feature - Gender gap in Stem sector: Support from parents is crucial to help girls excel

The Straits Times Feature: Addressing the Gender Gap in the STEM Sector

Fun Techtivities in February!