#include <stdio.h>
#include <stdlib.h>
#include <string.h>

/* run this program using the console pauser or add your own getch, system("pause") or input loop */
#define MAXSIZE 20
int main(int argc, char *argv[]) {
//	

	char A[MAXSIZE], B[5];
	scanf("%s %s", A, B);
	int i;
	int j;
	int lenA = strlen(A);
	int lenB = strlen(B);
	char temp;
	for (i = 0; i < lenA/2; ++i)
	{
		temp = A[i];
		A[i] = A[lenA-1-i];
		A[lenA - 1 - i] = temp;
		
	}
//	printf("%s\n", A);
	
	for ( i = 1; i < 3; i++)
	{
		B[i] = B[i + 1];
	}
	B[3] = '\0';
	
	temp = B[0];
	B[0] = B[2];
	B[2] = temp;
//	printf("%s", B);
	lenB = strlen(B);
	int *res = (int *)calloc(lenA + lenB - 2, sizeof(int));
//	int res[lenA + 2] = 0;
	
	
	for ( i = 0; i < lenB - 1; ++i)
	{
		for (j = 0; j < lenA - 1; ++j)
		{
			res[i + j] += (A[j] - '0') * (B[i] - '0'); 
//			printf("%d", res[i + j]);
			if (res[i + j] >= 10)
			{
				res[i + j + 1] += 1;
				res[i + j] %= 10;  
			}
		}
	}
	
	i =  i + j;
	
	while (res[i] == 0)
	{
		i--;
	}
//	printf("%d\n", i);
	if (i < 2)
	{
		printf("%d", 0);
		
	}
	else
	{
//		printf("%d\n", res[i]);
	
		while (i >=  2)
		{
			printf("%d", res[i--]);
		}
		
	}
//1000 0000  0000 0000
//9990 0000  0000 0000
	
	return 0;
}