Skip to main content
Commonmark migration
Source Link

##HighOrLowNotSelf##

HighOrLowNotSelf

Removes randomly lowest or highest intelligence player (but not self).

public class HighOrLowNotSelf extends Player{
    @Override
    public int vote(Set<Integer> ops) {
        int b=Math.round(Math.random()*1);
        int p;
        if(b==1) p=Collections.max(ops) else p=Collections.min(ops);
        if(p==getSmartness()) {
            return vote(ops);
        }
        return p;
    }
}

##HighOrLowNotSelf##

Removes randomly lowest or highest intelligence player (but not self).

public class HighOrLowNotSelf extends Player{
    @Override
    public int vote(Set<Integer> ops) {
        int b=Math.round(Math.random()*1);
        int p;
        if(b==1) p=Collections.max(ops) else p=Collections.min(ops);
        if(p==getSmartness()) {
            return vote(ops);
        }
        return p;
    }
}

HighOrLowNotSelf

Removes randomly lowest or highest intelligence player (but not self).

public class HighOrLowNotSelf extends Player{
    @Override
    public int vote(Set<Integer> ops) {
        int b=Math.round(Math.random()*1);
        int p;
        if(b==1) p=Collections.max(ops) else p=Collections.min(ops);
        if(p==getSmartness()) {
            return vote(ops);
        }
        return p;
    }
}
added 120 characters in body
Source Link
username.ak
  • 501
  • 2
  • 10

##MidPlayer####HighOrLowNotSelf##

Removes randomly lowlowest or high-intelligencehighest intelligence player (but not self).

public class MidPlayerHighOrLowNotSelf extends Player{
    @Override
    public int vote(Set<Integer> ops) {
        int b=Math.round(Math.random()*1);
        int p;
        if(b==1) return Collectionsp=Collections.max(ops) else return Collectionsp=Collections.min(ops);
        if(p==getSmartness()) {
            return vote(ops);
        }
        return p;
    }
}

##MidPlayer##

Removes randomly low or high-intelligence player.

public class MidPlayer extends Player{
    @Override
    public int vote(Set<Integer> ops) {
        int b=Math.round(Math.random()*1);
        if(b==1) return Collections.max(ops) else return Collections.min(ops);
    }
}

##HighOrLowNotSelf##

Removes randomly lowest or highest intelligence player (but not self).

public class HighOrLowNotSelf extends Player{
    @Override
    public int vote(Set<Integer> ops) {
        int b=Math.round(Math.random()*1);
        int p;
        if(b==1) p=Collections.max(ops) else p=Collections.min(ops);
        if(p==getSmartness()) {
            return vote(ops);
        }
        return p;
    }
}
Source Link
username.ak
  • 501
  • 2
  • 10

##MidPlayer##

Removes randomly low or high-intelligence player.

public class MidPlayer extends Player{
    @Override
    public int vote(Set<Integer> ops) {
        int b=Math.round(Math.random()*1);
        if(b==1) return Collections.max(ops) else return Collections.min(ops);
    }
}