def f(a,b,d): D=10*d;a>1>n%a==print(a,"*",n//a) for i in range(9):A=a+i%3*d+d;B=b-~i//3*d;A*B%D==n%D==f(A,B,D) while 1:n=int(input());f(0,0,1)