Add tasks for all the new languages
This commit is contained in:
parent
9dc3c2bb62
commit
bba7bfd280
13208 changed files with 134745 additions and 0 deletions
5
Task/Matrix-arithmetic/FunL/matrix-arithmetic-1.funl
Normal file
5
Task/Matrix-arithmetic/FunL/matrix-arithmetic-1.funl
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
def sgn( p ) = product( (if s(0) < s(1) xor i(0) < i(1) then -1 else 1) | (s, i) <- p.combinations(2).zip( (0:p.length()).combinations(2) ) )
|
||||
|
||||
def perm( m ) = sum( product(m(i, sigma(i)) | i <- 0:m.length()) | sigma <- (0:m.length()).permutations() )
|
||||
|
||||
def det( m ) = sum( sgn(sigma)*product(m(i, sigma(i)) | i <- 0:m.length()) | sigma <- (0:m.length()).permutations() )
|
||||
Loading…
Add table
Add a link
Reference in a new issue