5
81615
Is the above test case 8161 can also be the CB number which is the substring and aslo following the conditions. But in the question only 61 and 5 are considered to be CB number.
5
81615
Is the above test case 8161 can also be the CB number which is the substring and aslo following the conditions. But in the question only 61 and 5 are considered to be CB number.
hey @Jitinkansal it is mentioned in the question that “CB number once detected should not be sub-string or super-string of any other CB number.” which means once a character in the array is used for a CB number it cannot be used again. since 6 and 1 has been used in 61 they can’t be used in 8161.
ohhhh, so i might have not read the question properly.
sorry for that.