Tag Archives: merge sort

Is a sonnet also an algorithm?

1
An algorithm’s just a recipe
Computers follow. Machines are very good
At sorting ones from zeroes. I wish I could
Go as wantonly through everything,
This here, that there, no this, now switch, stay there,
But all my categories are too fluid.
In bubble sort you tackle pair by pair
Comparing each thing to the thing next to it.
Merge sort means you cluster first and then
Arrange your groups then group your groups again.
I didn’t know it had a name, the way
I’ve always tackled stacks that needed to be alphabetized.
Shouldn’t we see more order every day?
If algorithms truly run our lives.

2
An algorithm’s just a recipe
Computers follow. Machines are very good

Go as wantonly through everything,
At sorting ones from zeroes. I wish I could

But all my categories are too fluid.
This here, that there, no this, now switch, stay there,

In bubble sort you tackle pair by pair
Comparing each thing to the thing next to it.

Merge sort means you cluster first and then
Arrange your groups then group your groups again.

I didn’t know it had a name, the way
I’ve always tackled stacks that needed to be alphabetized.

If algorithms truly run our lives.
Shouldn’t we see more order every day?

3
An algorithm’s just a recipe
But all my categories are too fluid.
Go as wantonly through everything,
At sorting ones from zeroes. I wish I could
Computers follow. Machines are very good
This here, that there, no this, now switch, stay there,

If algorithms truly run our lives.
I didn’t know it had a name, the way
In bubble sort you tackle pair by pair
Shouldn’t we see more order every day?
Merge sort means you cluster first and then
Comparing each thing to the thing next to it.
Arrange your groups then group your groups again.
I’ve always tackled stacks that needed to be alphabetized.

4
An algorithm’s just a recipe
If algorithms truly run our lives.
But all my categories are too fluid.
Go as wantonly through everything,
I didn’t know it had a name, the way
In bubble sort you tackle pair by pair
Shouldn’t we see more order every day?
At sorting ones from zeroes. I wish I could
Computers follow. Machines are very good
Merge sort means you cluster first and then
Comparing each thing to the thing next to it.
Arrange your groups then group your groups again.
This here, that there, no this, now switch, stay there,
I’ve always tackled stacks that needed to be alphabetized.

_____

Lately when my son gets stuck on math(s), we’ve taken to watching various BBC specials on maths on Netflix. The latest we’re watching is on algorithms, with Marcus du Sautoy (pictured below, with a box symbolizing facial recognition algorithms).

NOTE: Part 2 is Bubble sort, but I didn’t take it through each step. It seemed boring and conveyed to me more clearly than ever why Bubble Sort takes longer than merge sort.

There are videos that show the different sorting algorithms. I find them hypnotic.

screen shot 2019-01-25 at 9.55.05 am