title: Multiply Large Integers Under Large Modulo
signature: def multiplyLargeIntegersUnderLargeModulo(a: Int, b: Int, mod_arg2: 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(a: Int, b: Int, mod_arg2: Int, expected: Int): String = {
      try {
          if (validateSolution(PLACEHOLDER_FN_NAME(a, b, mod_arg2),expected)) {
              "PASSED"
          } else{
              "FAILED"
          }
      }catch{
          case e: Exception => {e.getClass.getName}
      }
  
  }
  object QuestionEvaluator extends App {
  
      println(s"TEST-0...${driver(
        60, 24, 58, 
        48    
      )}")   
  
  
      println(s"TEST-1...${driver(
        46, 43, 29, 
        6    
      )}")   
  
  
      println(s"TEST-2...${driver(
        4, 50, 71, 
        58    
      )}")   
  
  
      println(s"TEST-3...${driver(
        67, 1, 66, 
        1    
      )}")   
  
  
      println(s"TEST-4...${driver(
        93, 35, 73, 
        43    
      )}")   
  
  
      println(s"TEST-5...${driver(
        89, 97, 8, 
        1    
      )}")   
  
  
      println(s"TEST-6...${driver(
        8, 78, 55, 
        19    
      )}")   
  
  
      println(s"TEST-7...${driver(
        53, 73, 22, 
        19    
      )}")   
  
  
      println(s"TEST-8...${driver(
        96, 92, 83, 
        34    
      )}")   
  
  
      println(s"TEST-9...${driver(
        38, 64, 83, 
        25    
      )}")   
  
  }
  
source_py: def multiply_large_integers_under_large_modulo(a, b, mod):
      res = 0
      a = (a % mod)
      while b:
          if (b & 1):
              res = ((res + a) % mod)
          a = ((2 * a) % mod)
          b >>= 1
      return res
source_cpp: long long multiply_large_integers_under_large_modulo(long long a, long long b, long long mod) {
    long long res = 0;
    a %= mod;
    while ( b ) {
      if ( b & 1 ) res = ( res + a ) % mod;
      a = ( 2 * a ) % mod;
      b >>= 1;
    }
    return res;
  }