#include <stdio.h>
#include <stdlib.h>
int main (void)
{
	int num;
	scanf("%d",&num);
	
	printf("%d的八進位是%o,十六進位是%x",num,num,num);
	return 0;
	
}