โ† Samsung questions
CodingReported in a candidate post, Sep 2020

String Replacement based on Substrings

Filed under Samsung

The question

Given a string formed by concatenating "one" and "two" in an arbitrary order, replace every occurrence of "one" with "oneone" and every occurrence of "twotwo" with "two".

No write-up yet. Related questions below have one.

Related Samsung questions

Collected from public candidate posts and coding forums. Updated Nov 2026.