fabbe680

2.2

Jan 19th, 2019
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. // Laboration 2, Assignment_2.cpp
  2. // Fabian Tjernström (fatj1700) 2018-11-21
  3.  
  4. #include <iostream>
  5. #include <iomanip>
  6.  
  7. using namespace std;
  8.  
  9. int main() {
  10.  
  11. int newLine = 0;
  12.  
  13. for(int count = 32; count <= 127; count++) {
  14. newLine++;
  15. std::cout << std::left << std::setw(4) << count;
  16. std::cout << std::left << std::setw(2) << "=";
  17. std::cout << std::left << std::setw(4) << char(count);
  18. if(newLine % 6 == 0) {
  19. std::cout << std::endl;
  20. }
  21. }
  22.  
  23. return 0;
  24. }
Advertisement
Add Comment
Please, Sign In to add comment