TIME:00:28/03:00:00 Submit Code Problem Statement Swaggy strings (100 Marks) Raju has a lot of strings but he does not like all of them.He likes only Swaggy strings. Now Raju wants to find the Swaggy String S from the given string N. A Swaggy string S has the following properties- It must be lexicographically largest. It must be a subsequence of original string N. Every character in S must appear at least K times. Input Format First line of input contains a String N. Second Line contains an Integer K. Note- All Characters in String N will be from (a-z) in lowercase. Constraints (1<=|N|<=100000) (1<=K<=100000) Output Format You must return a single String which is Swaggy. Sample TestCase 1 Input ritik 1 Output tk
Answers
Answered by
0
1200× 1000=2000
it correct hop
it correct hop
dharineesh47:
ammma hooo hop
Similar questions