title: Find Largest Prime Factor Number
signature: fun findLargestPrimeFactorNumber(n: Int): Int {
test_code: package main
  
  import kotlin.text.*
  import kotlin.math.*
  
  
  // SOLUTION CODE
  // ===================================
  PLACEHOLDER_CODE_BODY
  
  // TESTING CODE
  // ===================================
  fun validateSolution(actual:Int, expected:Int):Boolean{
    return actual.equals(expected)
  }
  fun driver(n: Int, expected:Int):String {
      try{
        if (validateSolution(PLACEHOLDER_FN_NAME(n), expected)) {
                return "PASSED"
        }
        return "FAILED"
      } catch (e: Exception){
        return e::class.simpleName as String
      }
  
  }
  
  fun main() {
      var result: String = ""
      result = driver(98, 7)
      println("TEST-0...${result}")
      
      result = driver(8, 2)
      println("TEST-1...${result}")
      
      result = driver(78, 13)
      println("TEST-2...${result}")
      
      result = driver(65, 13)
      println("TEST-3...${result}")
      
      result = driver(55, 11)
      println("TEST-4...${result}")
      
      result = driver(10, 5)
      println("TEST-5...${result}")
      
      result = driver(10, 5)
      println("TEST-6...${result}")
      
      result = driver(37, 37)
      println("TEST-7...${result}")
      
      result = driver(39, 13)
      println("TEST-8...${result}")
      
      result = driver(15, 5)
      println("TEST-9...${result}")
      
          
  }
  
  main()
source_py: def find_largest_prime_factor_number(n):
      maxPrime = (- 1)
      while ((n % 2) == 0):
          maxPrime = 2
          n >>= 1
      for i in range(3, (int(math.sqrt(n)) + 1), 2):
          while ((n % i) == 0):
              maxPrime = i
              n = (n / i)
      if (n > 2):
          maxPrime = n
      return int(maxPrime)
source_cpp: long long find_largest_prime_factor_number(long long n) {
    long long maxPrime = - 1;
    while ( n % 2 == 0 ) {
      maxPrime = 2;
      n >>= 1;
    }
    for ( int i = 3;
    i <= sqrt ( n );
    i += 2 ) {
      while ( n % i == 0 ) {
        maxPrime = i;
        n = n / i;
      }
    }
    if ( n > 2 ) maxPrime = n;
    return maxPrime;
  }