Luhn (mod 10) Check Digit Algorithm in MySQL


drop function if exists luhn;
drop function if exists luhn_check;

delimiter //

-- Function that calculates a Luhn (mod 10) check digit from a numeric string.
-- The behavior is undefined if the string contains anything else than digits.
-- Assumes that the string does...
 > Keep reading

Common ffmpeg parameters


Argument Description
-codecs Display codecs
-formats Display formats
-f fmt Force format "fmt"
-i filename Set input file name
-y Overwrite output file
-t secs Force duration to specific length (hh:mm:ss[.xxx])
-fs limit Set...
> Keep reading

My Idea for a Grand Opera


STAGE: A rural village in feudal Japan. A small, traditional Japanese house is nearby. Some cherry trees can be seen in the distance.


A samurai warrior enters the stage, inspecting his lands and his village. He starts singing the first...

> Keep reading

I Had a Strange and Curious Dream


I had a strange and curious dream last night
I dreamt my heart grew wings and then took flight
Flew far and wide o'er hills and fields of green
Above those golden clouds, to things unseen -
Plucking roses sweet that never grew
And singing...

> Keep reading

The Old Mainframe Computer


In a dark and gloomy dungeon
Racked by storms and thunder
A valiant server stood on guard
As lightning ripped the night asunder.
It stood there lonesome and forlorn
Working quietly in the freezing cold
But not a tear was seen
On its faithful color screen
This server...

> Keep reading

Would Be That My Dreams Took Flight


Ich halte meine Träume in meiner Hand
Und frage mich, warum fliegt ihr nicht?
Ihr liegt nur da, so leise und still
Keine Bewegung in meinem Gesicht.

Wenn sie endlich Flucht ergreifen
Wie schön wär' es nicht!
Hoch über die Erde fliegen sie
Hoch und stolz in...

> Keep reading

Wie ein dünner Nebel


Dann kommt das mal zu Ende.

Kein Wort wird mehr gesagt
Keinen Blick auf dir geworfen
Keine Träume mehr besteht.
Du sagst "auf wiedersehen"
Wir meinen's aber nicht.

Und wie ein dünner Nebel
Im Sonnenschein verjagt
So wirst du jetzt für mich
Immer schwacher, leichter, dünner
Bis nichts von dir...

> Keep reading



(Wrote this on the train home from Stenungsund a few years ago.)

His name was Tree.

For as long as he could remember, he had stood here in the middle of the forest. Deep in the far recesses of his slow, heavy...

> Keep reading

The Story of e, i, pi and the Elusive Minus One


There are three magic numbers in mathematics that stand out above all else. The first one is π, the relationship between a circle and it's diameter; there's e, the natural logarithm that permeates so many areas of mathematics; and i,...

> Keep reading

Writing Dialogue: Meet Chris and Rebecka


Writing dialogue is the most difficult thing I know. But watching Ally McBeal has really made me interested in writing again; and I think I realize that the whole purpose of dialogue is to establish a relationship in the story....

> Keep reading