functions.js
/**
 * squareOrDouble(n):
 * - receives a number n
 * - returns its square if it's odd
 * - returns its double if it's even
 *
 * e.g.
 * squareOrDouble(16) -> 32
 * squareOrDouble(9) -> 81
 */
- receives a number n
- returns its square if it's odd
- returns its double if it's even


- receives a number n - returns its square if it ' s odd - returns its double if it ' s even
function squareOrDouble(n) {
  if(isOdd(n)) return n*n;
  else return n*2;
}
function squareOrDouble ( n ) { if ( isOdd ( n ) ) return n * n ; else return n * 2 ; }
squareOrDouble(n):
 - receives a number n
 - returns its square if it's odd
 - returns its double if it's even
squareOrDouble ( n ) : - receives a number n - returns its square if it ' s odd - returns its double if it ' s even
// Your code here