This useful piece of code is able to figure out if an input is a "~" or anything else. When may this be useful? I don't know.
This code will run on any SPL (Shakespeare Programming Language) translator. To find out more about SPL, the website is here http://shakespearelang.com/ The specific translator I used was https://github.com/zmbc/shakespearelang
Have fun..