You are viewing a single comment's thread. Return to all comments →
JavaScript
function catAndMouse(x, y, z) { if((Math.abs(x-z)>Math.abs(y-z))){ return "Cat B"; } else if((Math.abs(x-z)<Math.abs(y-z))){ return "Cat A"; } else{return "Mouse C";} }
Cats and a Mouse
You are viewing a single comment's thread. Return to all comments →
JavaScript