Create a gist now

Instantly share code, notes, and snippets.

@ssaurel /
Last active Jun 16, 2017

What would you like to do?
Add Operation for the Countdown Math Game on the SSaurel's Channel
package com.ssaurel.countdowngame;
public class Add implements Operation {
public int eval(int x, int y) {
int r = x + y;
if (r <= x || r <= y) {
return 0;
} else {
return r;
public String symbol() {
return "+";
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment