My first hackathon

Published by Dev Kordeš on 02/23/2018

Reminiscing about my first 24-hour coding hackhathon, back in 2015, that kickstarted my love for hackathons. It helped that our team won.

What is a hackathon

From Wikipedia :

A hackathon (also known as a hack day, hackfest or codefest) is a design sprint-like event in which computer programmers and others involved in software development, including graphic designers, interface designers, project managers, and others, often including subject-matter-experts, collaborate intensively on software projects.

The goal of a hackathon is to create usable software. Hackathons tend to have a specific focus, which can include the programming language used, the operating system, an application, an API, or the subject and the demographic group of the programmers. In other cases, there is no restriction on the type of software being created.

In short, a coding hackathon is a 24-hour event where you generally start coding from scratch and finish the product before the bell.

Hackathon - Hackathon bell (from my 2nd Hackathon) indicating the end

Why is a hackathon

Hackathons are more often than not organized by companies and organizations - some hackathons are public, letting anyone participate, while others are internal, letting only the members of the organization participate.

Public hackathons

Public ones are often organized by a company and often have some rules set in place, such as "projects need to make use of X product". This is often used as a way for the organizing company to find new ideas in how to use their product. Or plainly to raise awareness.

Sometimes the rules are more goal-centered rather than product-centered, such as "projects need to tackle X problem".

Internal hackathons

I've never been to an internal one, but I imagine those are often focused on finding a solution to a problem, brainstorming new ideas or they're just a teambuilding event.

Here's Facebook's post (2012) about their internal hackathons. Fun fact: FB's like button, chat and timeline all started as an idea at an internal hackathon.

Aimless hackathons

These can be public or internal and are rarest in my experience. These are hackathons where there's no set goal. The university hackathons in my country fit here - the projects are judged purely based on an innovative idea and cool implementation. They don't need to solve a real-world problem or use a specific technology.

Hackathon spirit

But my first hackathon was organized by Slovenian's largest university. And as such a) there was NO goal b) there was no product placement. Basically - "go wild, do what you want, impress us". And those are the best kind. Of course, there were plenty of sponsors looking for talent to hire (and many provided either awards or gadgets to use with our projects), but they weren't judges for the main prize.

One of the best things about hackathons is the spirit, the hacking culture, the fact that people are more than happy to help you with an issue, regardless of the fact that it's still technically "a competition". Yes, most of us are introverted, so you have to go a bit out of your comfort zone and approach random people who have interesting projects on their table. But it's worth it! Every time I just asked someone about their project they were more than willing to talk about it and every time I asked someone for help they went out of their way and spent a decent amount of time helping our team with a problem we had. Great times were had by everyone.

Our project

What it was

We decided to build something with Muse headband (provided by the organizers). Of course the first hour or two we were extremely optimistic. We tried to make it identify how you're feeling and then go on from there. Regardless of our approach (trying to recognize facial expressions, brain movements...), we never even got close to that.

So we decided to build a music-taste recognition device with some additional perks. The basic idea was that the user would have to nod their head in some beat and the device would calculate beats-per-minute and automatically find a song that matches that BPM.

How we built it

What we used

We mainly used Python. Which is also the basis of our team's name - PyPhy + Dev (PyPhy = Python Physics, + Dev = plus me :)). Our team was 3 physicists, we used Python because that's what they all love and I have no huge preference. In fact, I was already somewhat familiar with BeautifulSoup for Python as I've used it before for web scraping. So Python would probably be my choice as well.

We also used HTML/CSS for playing the music video and visualization of the whole thing.


Muse headband has some number of very sensitive sensors and you can get the raw data of their output. Gyroscope was the most important one. Now in my team, I had 3 physicists, so they took care of fine-tuning the data to recognize when a nod is being produced. They did a fine job with that, it felt correct.

Me on the other hand, I found a website ( ) that has a list of songs and their rough BPM. I created a function that takes BPM as input and returns an array of songs that match that BPM. The songs are found through scraping the website with BeautifulSoup.

Then I queried Youtube for that song and we embedded the first match into our web app.


Now, so far there was nothing particularly impressive about the whole product. There was no need for Muse headband since every phone has a gyroscope.

But earlier in the day our fantastic physicists realized that, while we couldn't match brain movement well, we very much could recognize a) an eye-blink and b) jaw-clenching. So let's put that to use since we still had a few hours remaining.

So what we did was, we incorporated blinking, so that if you blink your eyes twice in rapid succession, the song would play/pause. And we added that if you clench your jaws for 5 seconds the whole app would restart and let you pick another beat.

That made the whole project far more impressive. Not every university hackathon project incorporates jaw-clenching and blinking! Ours did. And it was fine-tuned well enough. Along with appeasing to the demo gods our presentation went smoothly (we actually took first 5 seconds of the presentation to pray to the demo gods).


So somehow the judges decided that our useless little project was more impressive than the others. Lovely day altogether finished on a real high!

Presentation video

Shitty code

This website uses  Google Analytics  cookies. Beware.