Driver program to test above functions
public static void Main ( ) { String binary = "01001" ; Console . WriteLine ( " Gray ▁ code ▁ of ▁ " + binary + " ▁ is ▁ " + binarytoGray ( binary ) ) ; String gray = "01101" ; Console . Write ( " Binary ▁ code ▁ of ▁ " + gray + " ▁ is ▁ " + graytoBinary ( gray ) ) ; } }