/* Program 4.2.1 from C++ Programming Lecture notes  */

/* Author: Rob Miller and William Knottenbelt
   Program last changed: 30th September 2023 */

/* This program prints a table of ASCII characters. */ 

#include <iostream>
using namespace std;

int main()
{
	int number;
	char character;
	
	number = 32;
	while (number <= 126)   /* or: for (;number <= 126;) */
	{
		character = number;
		cout << "The character '" << character;
		cout << "' is represented as the number ";
		cout << number << " in the computer.\n";
		number++;
	}
	
	return 0;
}
