Skip to content

Instantly share code, notes, and snippets.

@masak
Created December 22, 2012 18:23
Show Gist options
  • Save masak/4360326 to your computer and use it in GitHub Desktop.
Save masak/4360326 to your computer and use it in GitHub Desktop.
Problem compiling the Haskell code
import qualified Data.MultiSet as MultiSet
limit :: Int
limit = 100
products :: MultiSet.MultiSet Int
products = MultiSet.fromList [ x * y | x <- [2..limit], y <- [x+1..limit-x] ]
solutions :: [(Int, Int)]
solutions = [(4, 13)]
main :: IO ()
main = mapM_ print solutions
$ ghc -o haskell-solution haskell-solution.hs
haskell-solution.o: In function `rv0_info':
(.text+0x2d7): undefined reference to `__stginit_multisetzm0zi2zi1_DataziMultiSet_'
collect2: ld returned 1 exit status
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment