Skip to main content
Rollback to Revision 1
Source Link
xnor
  • 146.6k
  • 26
  • 279
  • 652

Haskell, 6277 bytes

a%h%(ba:t)=a=h-ba:b%ta%t
a%_=[a]h%_=[h]
f(h:t)=h:foldr(%)[](f$mapf$zipWith((/).(-h+)t)t[1..])
f e=e

Try it online!Try it online!

Haskell, 62 bytes

a%(b:t)=a-b:b%t
a%_=[a]
f(h:t)=h:foldr(%)[](f$map(-h+)t)
f e=e

Try it online!

Haskell, 77 bytes

h%(a:t)=h-a:a%t
h%_=[h]
f(h:t)=h:foldr(%)[](f$zipWith((/).(-h+))t[1..])
f e=e

Try it online!

deleted 34 characters in body
Source Link
xnor
  • 146.6k
  • 26
  • 279
  • 652

Haskell, 7762 bytes

h%a%(ab:t)=h=a-ab:a%tb%t
h%_=[h]a%_=[a]
f(h:t)=h:foldr(%)[](f$zipWith((/).f$map(-h+))t[1..]t)
f e=e

Try it online!Try it online!

Haskell, 77 bytes

h%(a:t)=h-a:a%t
h%_=[h]
f(h:t)=h:foldr(%)[](f$zipWith((/).(-h+))t[1..])
f e=e

Try it online!

Haskell, 62 bytes

a%(b:t)=a-b:b%t
a%_=[a]
f(h:t)=h:foldr(%)[](f$map(-h+)t)
f e=e

Try it online!

Source Link
xnor
  • 146.6k
  • 26
  • 279
  • 652

Haskell, 77 bytes

h%(a:t)=h-a:a%t
h%_=[h]
f(h:t)=h:foldr(%)[](f$zipWith((/).(-h+))t[1..])
f e=e

Try it online!