Data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 7387c8f97b
commit cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions

View file

@ -0,0 +1,15 @@
// Display a linear combination. Nigel Galloway: March 28th., 2018
let fN g =
let rec fG n g=match g with
|0::g -> fG (n+1) g
|1::g -> printf "+e(%d)" n; fG (n+1) g
|(-1)::g -> printf "-e(%d)" n; fG (n+1) g
|i::g -> printf "%+de(%d)" i n; fG (n+1) g
|_ -> printfn ""
let rec fN n g=match g with
|0::g -> fN (n+1) g
|1::g -> printf "e(%d)" n; fG (n+1) g
|(-1)::g -> printf "-e(%d)" n; fG (n+1) g
|i::g -> printf "%de(%d)" i n; fG (n+1) g
|_ -> printfn "0"
fN 1 g

View file

@ -0,0 +1 @@
fN[-1;-2;0;-3]

View file

@ -0,0 +1 @@
fN [1;2;3]

View file

@ -0,0 +1 @@
fN [0;1;2;3]

View file

@ -0,0 +1 @@
fN[1;0;3;4]

View file

@ -0,0 +1 @@
fN[1;2;0]

View file

@ -0,0 +1 @@
fN[0;0;0]

View file

@ -0,0 +1 @@
fN[1;1;1]

View file

@ -0,0 +1 @@
fN[-1;-1;-1]