Code generator

Jan 24, 2019 at 9:20am
Hey! Does anyone have and idea how to make a program which shows me all the 6 digit combinations of 1 and 0 ? Thank you!
Jan 24, 2019 at 9:26am
Print in binary, the result of
for ( int i = 0 ; i < (1<<6)-1 ; i++ )
Jan 24, 2019 at 9:28am
1
2
3
#include <iostream>
#include <bitset>
int main() { for ( int i = 0; i < 64; i++ ) std::cout << std::bitset<6>( i ) << '\n'; }
Topic archived. No new replies allowed.