class Quizful {
private int xp = 0;
static void add(Quizful q, int value) {
q.xp = q.xp + value;
}
static void multiply(int xp, int value) {
xp = xp * value;
}
public static void main(String[] args) {
Quizful q = new Quizful();
add(q, 2);
multiply(xp, 3);
System.out.print(q.xp);
}
}
Login in to like
Login in to comment