|
@ -1,8 +1,17 @@ |
|
|
#include "fakultaet.h" |
|
|
#include "fakultaet.h" |
|
|
|
|
|
|
|
|
int berechneFakultaetInt(int zahl) { |
|
|
int berechneFakultaetInt(int zahl) { |
|
|
return 0; |
|
|
|
|
|
|
|
|
if (zahl == 0 || zahl == 1) { |
|
|
|
|
|
return 1; |
|
|
|
|
|
} else { |
|
|
|
|
|
int fakultaet = 1; |
|
|
|
|
|
for (int i = 2; i <= zahl; ++i) { |
|
|
|
|
|
fakultaet *= i; |
|
|
|
|
|
} |
|
|
|
|
|
return fakultaet; |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
double berechneFakultaetDouble(double a, double b) { |
|
|
double berechneFakultaetDouble(double a, double b) { |
|
|
return 0; |
|
|
return 0; |
|
|
} |
|
|
} |