How can I decrease the time complexity for this question?
问题 I am solving a problem such that for every given number between range (inclusive of boundary integers), I calculate the sum of the modified value of those numbers. For example, x = 388,822,442 f(388,822,442)=3800200402 i.e; makes zeros for the identical digits. f(x) is modified value. I iterated through each digit of an integer and made it zero if repeated. BufferedReader bf = new BufferedReader(newInputStreamReader(System.in)); String s[], s1[]; s = bf.readLine().trim().split("\\s+"); s1 =