This repository has been archived on 2021-05-17. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
scientificComputing/programming/exercises/factorialscripta.m
2016-11-22 15:14:06 +01:00

7 lines
88 B
Matlab

n = 5;
x = 1;
for i = 1:n
x = x * i;
end
fprintf('Factorial of %i is: %i\n', n, x)