Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int main() {
- cout << "DECIMAL BINARY HEXDECIMAL BCD" << endl;
- for (int num = 0; num <= 255; num++) {
- cout << num << " ";
- cout << binary(num) << " ";
- cout << hex(num) << " ";
- cout << bcd(num);
- cout << endl;
- }
- return 0;
- }
- ofstream outputFile("program0.txt");
- //... An example of how to write to a txt file
- outputFile << "writing to file";
Add Comment
Please, Sign In to add comment