>#WIP
hsunfold :: (t -> Bool) -> (t -> a) -> (t -> t) -> t -> [a] unfold p h t x | p x = [] |otherwise = h x : unfold p h t (t x)
p
h
t
x