Time QR Code

Above is a QR code that indicates the time. It updates every second. Click on it to make it fullscreen. The message in it has three characters: the first represents hours, the middle represents minutes, and the third represents seconds. To get the time, look up the characters in the table below.

CodeNumber
A0
B1
C2
D3
E4
F5
G6
H7
I8
J9
K10
L11
M12
N13
O14
P15
Q16
R17
S18
T19
U20
V21
W22
X23
Y24
Z25
a26
b27
c28
d29
e30
f31
g32
h33
i34
j35
k36
l37
m38
n39
o40
p41
q42
r43
s44
t45
u46
v47
w48
x49
y50
z51
052
153
254
355
456
557
658
759
860
961

The number 60 rarely appears, but it does when there is a leap second. The number 61 is there just in case.

The Scattered Squares

The little white square that are scattered on the outside of the QR code are leftovers. Every QR code uses both black and white squares, but because the background is black, only the white squares are animated. When one QR code has fewer white than the previous, the extra white squares are moved outside the QR code. If they still are not used by the next QR code, then they remain on the outside. They are never removed from this page until you close it or go somewhere else.

Why I Made This

This is a project through which I can practice combinatorial optimization. On each refresh, the squares must change their formation. The code that controls which square goes where is a great place to practice things like the assignment problem. Each square can go to any location, and each location can take any square. A square is a worker, and a location is a job. The cost of a worker doing a job is the distance from the worker’s current location to the new location. Minimizing the total distance that is traveled by all squares upon each refresh is a case of the assignment problem.