This is a JavaScript version of bpb's Wahl-O-Mat