Answer to Question 12B-2

int numGood(int a, int b)
{
  int count = 0;
  for(int k = a; k <= b; k++)
  {
    if(isGood(k))
    {
      count++;
    }
  }
  return count;
}