Not to repeat number

Hello everyone,
I have this number(1225333788).
Here I want numbers are not repeat.

Output is : 125378

What condition is prefer?

I think u can try this logic

assign

a = “1225333788”

Now split the string a into characters

b= a.ToCharArray().Distinct

Now join it again

c = String.Join("",b.ToArray())

Hope this helps

Mark it as solution if it helps

Thanks and regards

Nived N

4 Likes