If you are browsing this forum, it is a safe assumption to believe you know of the Fibonacci Series.
After having a couple of minutes, and some random thoughts, I put together a little piece of code that will print this series out to a file.
Private Sub FibWrite(ByVal iMax As Int64) Dim sw As New StreamWriter("Path") Dim n0 As Int64 = 0 Dim n1 As Int64 = 1 Try For i = 0 To iMax Dim iTemp As Int64 = n1 n1 = n1 + n0 n0 = iTemp sw.WriteLine(n1) Next Catch ex As Exception MsgBox(ex.ToString) sw.WriteLine(ex.Message) Finally sw.Close() sw.Dispose() End Try End Sub
I reached a total of 90 iterations before overflow occurs.
Let's have some fun with this, shall we?