Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save IQAndreas/6958147 to your computer and use it in GitHub Desktop.
Save IQAndreas/6958147 to your computer and use it in GitHub Desktop.
var vowels = ['a', 'e', 'i', 'o', 'u'];
'abcdefghijklmnopqrstuvwxyz'.replace(/[a-z]/g, function (l) {
if (l === 'z') return 'A';
l = String.fromCharCode(l.charCodeAt(0) + 1);
return (vowel.indexOf(l) != -1) ? l.toUpperCase() : l;
}); //bcdEfghIjklmnOpqrstUvwxyzA
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment