This repository has been archived on 2021-05-17. You can view files and clone it, but cannot push or open issues or pull requests.
scientificComputing/programming/code/facultyWhileLoop.m
2015-11-06 12:10:48 +01:00

7 lines
110 B
Matlab

n = 5;
counter = 1;
x = 1;
while counter <= n
x = x * counter;
end
fprintf('Faculty of %i is: %i\n', n, x)