samedi 18 avril 2020

How to get a unique character in the string also it should be in the same sequence as the original string in C++ [duplicate]

As I tried unordered_set, but it changes the occurrence of character

Input : hereiamstackerrank

output: nkctseharim (with unordered_set)

But I want something like this: heriamstckn

Aucun commentaire:

Enregistrer un commentaire