title: Program Print Sum Given Nth Term 1
signature: function programPrintSumGivenNthTerm1($n) {
test_code: <?php
  
  
  // SOLUTION CODE 
  // ============================================
  PLACEHOLDER_CODE_BODY
  
  // TESTING CODE 
  // ============================================
  function validateSolution($actual, $expected){
      return abs($actual - $expected) < 1e-06;
  }
  
  function driver($n, $expected){
      try{
        if (validateSolution(PLACEHOLDER_FN_NAME($n), $expected)){
          return "PASSED";
        }
        return "FAILED";
      }
      catch (Exception $exception_obj) {
        return get_class($exception_obj);
      }
  }
  
  function main(){
      printf("TEST-0...%s\n",driver(
        42, 
        1764.0));
      
      printf("TEST-1...%s\n",driver(
        40, 
        1600.0));
      
      printf("TEST-2...%s\n",driver(
        67, 
        4489.0));
      
      printf("TEST-3...%s\n",driver(
        73, 
        5329.0));
      
      printf("TEST-4...%s\n",driver(
        18, 
        324.0));
      
      printf("TEST-5...%s\n",driver(
        16, 
        256.0));
      
      printf("TEST-6...%s\n",driver(
        74, 
        5476.0));
      
      printf("TEST-7...%s\n",driver(
        33, 
        1089.0));
      
      printf("TEST-8...%s\n",driver(
        92, 
        8464.0));
      
      printf("TEST-9...%s\n",driver(
        22, 
        484.0));
      
  }
  
  main();
  ?>
source_py: def program_print_sum_given_nth_term_1(n):
      return math.pow(n, 2)
source_cpp: int program_print_sum_given_nth_term_1(long n) {
    return pow ( n, 2 );
  }