Open kevinbarabash opened 4 years ago
If I understand correctly, this can also be implemented as
meta f g = hylo g f
Which then prompts the question, why not just use hylo
? The implementation looks like it's in the reverse order, but it's really not, because the proposed solution also flips the argument order for Algebra
and Coalgebra
, so it ends up being actually an identical implementation with the first two arguments swapped.
I think this is this is the correct implementation (I followed what
hylo
does but reverse the order):