Skip to content

Instantly share code, notes, and snippets.

@thurask
Last active August 13, 2017 18:49
Show Gist options
  • Save thurask/468e07d8f7edd81fe669036bf5108efd to your computer and use it in GitHub Desktop.
Save thurask/468e07d8f7edd81fe669036bf5108efd to your computer and use it in GitHub Desktop.
Convert BB DMY stamp to human readable date
def dconv(datecode):
table = "123456789ABCDEFGHIJKLMNOPQRSTUV"
dd, mm, yy = datecode.upper()
dx = table.index(dd) + 1
mx = table.index(mm) + 1
yx = table.index(yy) + 2001
return "{0}/{1:0>2}/{2:0>2}".format(yx, mx, dx)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment