#include <iostream>
using namespace std;

int main() {
	int input;
	int greatest;
	int lowest;
	
	cout << "Enter a number from 0 -99. Enter -99 when you are done.\n";
	cin >> input;

	lowest = input;
	greatest = input;
	
	while (input != -99)
	{
		if (input < lowest )
		{
			lowest = input;
		}
		
		if (input > greatest)
		{
			greatest = input;
		}
		
		cin >> input;
	
	}
	
	cout << "Lowest number is " << lowest << endl;
	cout << "Greatest number is " << greatest << endl;
	
	return 0;
}