Initial data commit
This commit is contained in:
parent
72d218235f
commit
f23f22d71c
199087 changed files with 3378941 additions and 0 deletions
12
Task/Dot-product/Visual-Basic-.NET/dot-product.vb
Normal file
12
Task/Dot-product/Visual-Basic-.NET/dot-product.vb
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
Module Module1
|
||||
|
||||
Function DotProduct(a As Decimal(), b As Decimal()) As Decimal
|
||||
Return a.Zip(b, Function(x, y) x * y).Sum()
|
||||
End Function
|
||||
|
||||
Sub Main()
|
||||
Console.WriteLine(DotProduct({1, 3, -5}, {4, -2, -1}))
|
||||
Console.ReadLine()
|
||||
End Sub
|
||||
|
||||
End Module
|
||||
Loading…
Add table
Add a link
Reference in a new issue