Could someone please give me a example of a function that would use this data type:
function :: Num b => b -> a -> [a]
function a b = ...
Also ideally a would be a string.
No this is not homework xD I just need an example for a project.
I have tried take b (repeat a) but I get the error
Could not deduce (b ~ Int)
from the context (Num b)
This would work (it’s a function that fits the type description):