Crowdfunding Roundup #2

This is a new series of posts, called Crowdfunding Roundup where I list interesting projects I found on crowdfunding platforms (Kickstarter, Indiegogo…). These will be mainly code & electronics projects. This is the 2nd roundup.

Crowdfunding Roundup #1

This is a new series of posts, called Crowdfunding Roundup where I list interesting projects I found on crowdfunding platforms (Kickstarter, Indiegogo…). These will be mainly code & electronics projects.

#MonthOfCode - Day 29: golf

My entry for the 29th day of the month of code. The theme for today is: golf.

Code golf is like real golf: use the fewest number of strokes. Here’s yesterday’s code, reduced by hand from 2170 characters to 772.

Code after the break.

#MonthOfCode - Day 28: race

My entry for the 28th day of the month of code. The theme for today is: race.

You are the red player, can you beat the computer? Click to start the game, then click like crazy to win the race!

Code after the break.

#MonthOfCode - Day 26: malicious

My entry for the 26th day of the month of code. The theme for today is: malicious.

I’ve not written today’s code but let’s look at it anyway: :(){ :|:& };:. It’s a fork bomb for a UNIX shell (bash for instance).

With some formatting:

1
2
3
4
:() {
: | : &
};
:

It’s a function called :! Let’s rename it:

1
2
3
4
fork_bomb() {
fork_bomb | fork_bomb &
};
fork_bomb

A function is defined then called. Inside the function, it calls itself twice, in parallel (that’s what the | does) and it’s non-blocking (that’s what the & does). This means that you can’t kill it with Ctrl-C.