Pregunta de entrevista de Cognizant

Can you please write a factorial code