Skip to content

Instantly share code, notes, and snippets.

@QuatoHub
Created September 6, 2021 16:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save QuatoHub/677cf6c9522132c13a0f940c766db705 to your computer and use it in GitHub Desktop.
Save QuatoHub/677cf6c9522132c13a0f940c766db705 to your computer and use it in GitHub Desktop.
// 문자열을 입력받아 문자열을 구성하는 각 문자를 키로 갖는 객체를 리턴
let output = countAllLetters('apple');
console.log(output); // --> {a: 1, p: 2, l: 1, e: 1}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment