Select Git revision
WangTile.java
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
Loot.java 485 B
public class Loot {
private int weight, value;
private final float ratio;
public Loot(int weight, int value) {
this.weight = weight;
this.value = value;
this.ratio = (float) value/weight;
}
public String toString(){
return weight+" "+value+" "+ratio;
}
public float getRatio(){
return ratio;
}
public int getWeight(){
return weight;
}
public int getValue(){
return value;
}
}