title: Sum Factors Number
signature: def sumFactorsNumber(n: Int) = {
test_code: import scala.collection.mutable.HashMap
  import scala.collection.immutable.HashSet
  
  
  // SOLUTION CODE
  // ============================================
  PLACEHOLDER_CODE_BODY
  
  
  // TESTING CODE 
  // ============================================
  def validateSolution(actual: Int , expected: Int): Boolean = {
      actual.toString == expected.toString
  }
  
  def driver(n: Int, expected: Int): String = {
      try {
          if (validateSolution(PLACEHOLDER_FN_NAME(n),expected)) {
              "PASSED"
          } else{
              "FAILED"
          }
      }catch{
          case e: Exception => {e.getClass.getName}
      }
  
  }
  object QuestionEvaluator extends App {
  
      println(s"TEST-0...${driver(
        76, 
        140    
      )}")   
  
  
      println(s"TEST-1...${driver(
        21, 
        32    
      )}")   
  
  
      println(s"TEST-2...${driver(
        4, 
        7    
      )}")   
  
  
      println(s"TEST-3...${driver(
        49, 
        57    
      )}")   
  
  
      println(s"TEST-4...${driver(
        35, 
        48    
      )}")   
  
  
      println(s"TEST-5...${driver(
        55, 
        72    
      )}")   
  
  
      println(s"TEST-6...${driver(
        43, 
        44    
      )}")   
  
  
      println(s"TEST-7...${driver(
        39, 
        56    
      )}")   
  
  
      println(s"TEST-8...${driver(
        36, 
        91    
      )}")   
  
  
      println(s"TEST-9...${driver(
        5, 
        6    
      )}")   
  
  }
  
source_py: def sum_factors_number(n):
      result = 0
      for i in range(2, (int(math.sqrt(n)) + 1)):
          if ((n % i) == 0):
              if (i == (n / i)):
                  result = (result + i)
              else:
                  result = (result + (i + (n // i)))
      return ((result + n) + 1)
source_cpp: int sum_factors_number(int n) {
    int result = 0;
    for ( int i = 2;
    i <= sqrt ( n );
    i ++ ) {
      if ( n % i == 0 ) {
        if ( i == ( n / i ) ) result += i;
        else result += ( i + n / i );
      }
    }
    return ( result + n + 1 );
  }