summaryrefslogtreecommitdiff
path: root/1670/CH9/EX9.1/9_1.sce
blob: cee4b573511a04bbcebc9119040af7ef36bcee9c (plain)
1
2
3
4
5
6
7
8
9
10
//Example 9.1
//Recurrence formula
//Page no. 288
clc;clear;close;

y(1)=5;
for i=2:7
    y(i)=2*y(i-1)
    printf('\ny(%i) = %g\n',i-1,y(i-1))
end