Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
14
Task/Van-Eck-sequence/Visual-Basic-.NET/van-eck-sequence.vb
Normal file
14
Task/Van-Eck-sequence/Visual-Basic-.NET/van-eck-sequence.vb
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
Imports System.Linq
|
||||
Module Module1
|
||||
Dim h() As Integer
|
||||
Sub sho(i As Integer)
|
||||
Console.WriteLine(String.Join(" ", h.Skip(i).Take(10)))
|
||||
End Sub
|
||||
Sub Main()
|
||||
Dim a, b, c, d, f, g As Integer : g = 1000
|
||||
h = new Integer(g){} : a = 0 : b = 1 : For c = 2 To g
|
||||
f = h(b) : For d = a To 0 Step -1
|
||||
If f = h(d) Then h(c) = b - d: Exit For
|
||||
Next : a = b : b = c : Next : sho(0) : sho(990)
|
||||
End Sub
|
||||
End Module
|
||||
Loading…
Add table
Add a link
Reference in a new issue