Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
$c->{NonCont} = 'Elected';
}
-$stage = 1;
-
-sortballots @allvotes;
-countballots();
-computequota();
+$stage = 0;
for (;;) {
$stage++;
+ sortballots @allvotes if $stage == 1;
+
my $seats_remain = $seats
- grep { ($_->{NonCont} // '') eq 'Elected' } values %cands;
if (continuing() <= $seats_remain) {
countballots();
+ computequota if $stage == 1;
+
my $c = select_best_worst
sub { $_->{Total} >= $quota },
sub { $_ > $quota },