class Main {
public static void main(String[] args) {
isFactorial(19.2);
}
public static void isFactorial(double num){
long factorial = 1;
if(num > 0 && num % 1 == 0.0){
int i = 1;
while (i <= num) {
factorial = factorial * i;
i++;
}
System.out.println("Factorial of " + num + " = " + factorial);
}
else{
System.out.println("Number should be greater than 0 and should be a integer");
}
}
}