Feeds
질문
How do I change the sign without altering the other and how can I do the factorial denominator? 1-1/3!+1/5!-1/7!+... and perform the sum?
disp('serie 4: 1-1/3!+1/5!-1/7!+...' ) n=input('Enter a number: '); sum=0; for j=1:2:n sum = sum + 1/j; end disp('the ...
3년 초과 전 | 답변 수: 1 | 0
1
답변질문
How can I change the numbers to negative without altering the positive ones and make a sum of that? This is the serie 1-2+3-5+8-13+21-34+...
n=8; F=[1 2]; suma=0; for i=3:n F(i)=F(i-1) + F(i-2); end disp(F) this is only for show the positive serie
3년 초과 전 | 답변 수: 1 | 0
