S&P Global Interview Question

How do you reverse a string ? This question was asked in first round.

Interview Answer

Anonymous

Aug 14, 2024

I actually said I would do it using empty string and traversing from last. But the interviewer expected to use the StringBuilder because it has the direct method reverse().