/***
 * iostream, namespace, and  int main() are not required for the exam solution.
 * They are used here to make sure the snippet compiles correctly.
 */
#include <iostream>
using namespace std;
int main()
{
	// BEGIN Exam Solution --- there is pretty much one straight-forward
	// way to write the solution, minor details and coding style can change
	// the essential code only a little.
	
	int x, y, z;
	while( cin >> x >> y >> z ) {  // REQUIREMENT: read in groups of 3 ints

		// REQUIREMENT: use a bool flag to determine if an endl should be 
		// printed.
		bool need_endl = false;

		// REQUIREMENT: if the first is negative, print the second
		if( x < 0 ) {
			cout << y << " "; // make sure there will be whitespace separating
			need_endl = true; // outputs
		}

		if( '0' <= y && y <= '9' ) { // REQUIREMENT: if it is a digit...
			cout << char( z );       // ... print the third integer as a char
			need_endl = true;
		}

		// REQUIREMENT: display endl if required
		if( need_endl ) cout << endl;

	}

	// REQUIREMENT:  excellent silently on input failure (so, no code here...)
	
	// END Exam Solution
	
	return 0;  // needed compile check
}

