I know how to use recursion to reverse a list, but I am trying to use foldl to make it more efficient. My code is as follow:
reverse list = foldl (++) [] (map (\x -> [x]) list)
When running it in GHCi, it returns the same list as input. What goes wrong? I also try to finish it by foldr but it does not show any change.