Import Set qualified
Add ordNubBy
Compile with -Wall
Fix warnings