Java -Programm, um Faktor für eine Nummer zu finden
public static void main(String[] args) {
Scanner input = new Scanner(System.in);
int num = input.nextInt();
int fact = 1;
for (int i = num; i > 0; i--) {
fact *= i;
}
System.out.println("factorial: "+fact);
}
Chathumal Sangeeth