Apply a callback to an array: Difference between revisions
Content added Content deleted
(→{{header|Visual Basic .NET}}: Doesn't work in VB 9) |
|||
Line 761: | Line 761: | ||
apply squaring (dup *) to each member of collection |
apply squaring (dup *) to each member of collection |
||
[1 2 3 4] [dup *] map |
[1 2 3 4] [dup *] map |
||
=={{header|Visual Basic .NET}}== |
|||
'''Platform:''' [[.NET]] |
|||
{{works with|Visual Basic .NET|9.0+}} |
|||
Dim intArray As Integer() = {1, 2, 3, 4, 5} |
|||
Array.ForEach(intArray, Function(i) Console.WriteLine(i * i)) |