I'm sure this is not the way the solution was intended to be found, but the answer might provide a clue as to what the intended solution method is.
Each line contains n, S(n) and Sigma{k=1 to n} S(k)
4 3 6
5 5 11
6 9 20
7 17 37
8 31 68
9 57 125
10 105 230
11 193 423
12 355 778
13 653 1431
14 1201 2632
15 2209 4841
16 4063 8904
17 7473 16377
18 13745 30122
19 25281 55403
20 46499 101902
21 85525 187427
22 157305 344732
23 289329 634061
24 532159 1166220
25 978793 2145013
26 1800281 3945294
27 3311233 7256527
28 6090307 13346834
DefDbl A-Z
Dim crlf$
Private Sub Form_Load()
Form1.Visible = True
Text1.Text = ""
crlf = Chr$(13) + Chr$(10)
a = 1: b = 1: c = 1
k = 3: tot = 3
For k = 4 To 28
d = a + b + c
a = b: b = c: c = d
tot = tot + d
Text1.Text = Text1.Text & k & Str(c) & Str(tot) & crlf
Next
Text1.Text = Text1.Text & crlf & " done"
End Sub
|
Posted by Charlie
on 2016-02-02 07:56:22 |