Skip to content

Instantly share code, notes, and snippets.

@puik
Created September 21, 2016 15:14
Show Gist options
  • Save puik/7b1199fb2e204d74e48148143b3dd589 to your computer and use it in GitHub Desktop.
Save puik/7b1199fb2e204d74e48148143b3dd589 to your computer and use it in GitHub Desktop.
c="442"
p=["None","Execute only","Write only","Write and Execute","Read only","Read and Execute","Read and Write","Read Write and Execute"]
def decode(c):
return("User: "+p[int(c[0])]+"\nGroup: "+p[int(c[1])]+"\nOthers: "+p[int(c[2])]+"\n")
decode(c)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment