Driver code
public static void Main ( String [ ] args ) { char [ ] bnum = "10010" . ToCharArray ( ) ; Console . WriteLine ( " Binary ▁ representation ▁ of ▁ next ▁ greater ▁ number ▁ = ▁ " + nextGreaterWithSameDigits ( bnum ) ) ; } }