aboutsummaryrefslogtreecommitdiff
path: root/src/Criteria.hs
diff options
context:
space:
mode:
authorJed Barber <jjbarber@y7mail.com>2017-01-27 17:39:05 +1100
committerJed Barber <jjbarber@y7mail.com>2017-01-27 17:39:05 +1100
commitb282e055140ff65879296d4654ad269cc7ff8185 (patch)
treeefb85ed0d03f3b5323cb9c01f1fab9bfb09bab72 /src/Criteria.hs
parent57d88b07166911a13b37aea54c4247097dc2d0fa (diff)
Code a lot cleaner, algorithm theoretically improved, yet still slow as fuck probably due to criteria parsing
Diffstat (limited to 'src/Criteria.hs')
-rw-r--r--src/Criteria.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Criteria.hs b/src/Criteria.hs
index 5df9cf1..7f46970 100644
--- a/src/Criteria.hs
+++ b/src/Criteria.hs
@@ -42,7 +42,8 @@ evaluate ballot preferences criteria =
isValidInput :: Typ.BelowLineBallot -> [Pref.Preference] -> Bool
isValidInput ballot preferences =
- all (\(x,y) -> x > 0 && x <= length ballot && y > 0 && y <= length ballot) preferences
+ all (\(x,y) -> x > 0 && x <= length ballot
+ && y > 0 && y <= length ballot) preferences