Gray codeHere is a program using recursion. And I think it will fulfill your need. [code]#include <iostream>...
Gray codeHere is non- recursive code. If you think it may help you then complete it. I'm posting a recursive ...