Next Greater Numerically Balanced Number at Sprinklr
Medium63.0% acceptance
This problem has 87.5% frequency at Sprinklr.
Problem Description
An integer `x` is **numerically balanced** if for every digit `d` in the number `x`, there are **exactly** `d` occurrences of that digit in `x`. Given an integer `n`, return _the**smallest numerically balanced** number **strictly greater** than _`n` _._
Read full problem and hintsTopics
Also asked at 4 companies
More Sprinklr Questions
Create Components With Same ValueHardApply Operations on Array to Maximize Sum of SquaresHardCount the Number of Powerful IntegersHardMaximize Score After N OperationsHardIsomorphic StringsEasy
View all Sprinklr questions