Company: HCL TECH

Difficulty: medium

Problem Statement

Character Repetition You are given a string `s` of length `n` containing lowercase English letters. Exactly one character occurs exactly twice and every other character occurs exactly once. Remove both occurrences of the repeated character and print the remaining string, preserving order. Input Format The first line contains `n`. The second line contains `s`. Output Format Print the modified string. Constraints `3 ≤ n ≤ 26`. Notes The result contains at least one character.

More HCL TECH OA questionsInterview experiences