Codewars DuplicateEncoder Java solution

Publicado el: 17 diciembre 2021
en el canal de: Dave Kirkwood
613
9

Duplicate Encoder is the third exercise that I have tried in CodeWars. Its a 6 kyu task. A string has to be converted into a series of brackets of the same length as the string. An open bracket is required if the character appears only once in the original string and a closed bracket represents a character that appears more than once in the original string.

My solution first loops through the string and counts each of the characters. It then loops back through the original string to create the sequence of brackets, based on the count of characters from the first loop.


En esta página del sitio puede ver el video en línea Codewars DuplicateEncoder Java solution de Duración hora minuto segunda en buena calidad , que subió el usuario Dave Kirkwood 17 diciembre 2021, comparta el enlace con amigos y conocidos, en youtube este video ya ha sido visto 613 veces y le gustó 9 a los espectadores. Disfruta viendo!