+ 3
How do you print duplicate characters from a string?
Can anyone tell me please how can we find duplicate characters from a string in Python, C, C#, Kotlin etc...
2 Antworten
+ 8
We don't give ready made codes here.. You have to attach your own attempt for further help..
But,
One of the way would be to take the characters in a map and keep track of the count of each characters.
Then, if the character count is greater than 1 then that means you found duplicate characters.
This is not exactly the code you want but hope this will give you some inspiration..
https://code.sololearn.com/c52HF0PbSr0Z/?ref=app
+ 1
Thank you, now it's clear to me... 😊