June 2018 Update
This commit is contained in:
parent
ba8067c3b7
commit
22f33d4004
5278 changed files with 84726 additions and 14379 deletions
13
Task/Dot-product/Elena/dot-product.elena
Normal file
13
Task/Dot-product/Elena/dot-product.elena
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
import extensions.
|
||||
import system'routines.
|
||||
|
||||
extension $op
|
||||
{
|
||||
method dotProduct array:array
|
||||
= self zip(array) by(:x:y)(x * y); summarize.
|
||||
}
|
||||
|
||||
program =
|
||||
[
|
||||
console printLine((1, 3, -5) dotProduct:(4, -2, -1)).
|
||||
].
|
||||
Loading…
Add table
Add a link
Reference in a new issue