#include<iostream>
#include<conio.h>
using namespace std;
class ReverseClass
{
	private :
		int t, Rev;
	public :
		int x;
		ReverseClass()
		{
			Rev = 0;
		}
		void Calculate()
		{
			for(t = x; t > 0; t /= 10)
				Rev = Rev * 10 + t % 10;
		}
		int GetReverse()
		{
			return Rev;
		}
};

int main()
{
	ReverseClass A;
	cout << "adad ra vared konid : ";
	cin >> A.x;
	A.Calculate();
	cout << "Natije " << A.x << " * " << A.GetReverse() << " = " << A.x * A.GetReverse() << endl;
	getch();
}

