No Duplicates

Given a string, remove any duplicate letters.

Example:

var input = "bookkeeper larry";

// Output: "bokepr lay"

Extra Credit:

  • Create a function that randomly removes a letter.
  • Create a function that scrambles the original string.
  • Create a function using regular expressions that remove all vowels.