← Walmart questions
CodingReported in a candidate post, Jul 2019

Next higher number using at most one swap

Filed under Walmart

Given a number as a string, find the strictly next greater number that can be formed by swapping at most one pair of digits. If no such greater number can be formed, return the original string or an…

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Walmart questions

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