Skip to content

Instantly share code, notes, and snippets.

@andrewyager
Last active September 13, 2021 23:55
Show Gist options
  • Save andrewyager/1b6908fd40ec8f1e05b08a2928dd0bab to your computer and use it in GitHub Desktop.
Save andrewyager/1b6908fd40ec8f1e05b08a2928dd0bab to your computer and use it in GitHub Desktop.
An implementation of the Ghostname generator.
#!/usr/bin/env python3
###
### An implementation of Nathan W. Pyle's Ghostname
### https://www.facebook.com/nathanwpyle2/posts/405022030992924
### https://twitter.com/nathanwpyle/status/1437233812203782145
###
name = input("Enter your name: ")
outname = ""
for l in name:
l = l.lower()
if l == "a":
outname = outname + "at"
elif l == "e":
outname = outname + "eboo"
elif l == "h":
outname = outname + "s"
elif l == "n":
outname = outname + "noo"
elif l == "r":
outname = outname + "reee"
elif l == "y":
outname = outname + "yoo"
else:
outname = outname + l
outname = outname[0].upper() + outname[1:]
print(f"Your ghost name is {outname}")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment