title: Fast Multiplication Method Without Using Multiplication Operator Russian Peasants Algorithm
signature: def fastMultiplicationMethodWithoutUsingMultiplicationOperatorRussianPeasantsAlgorithm(a: Int, b: 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, expected: Int): String = {
      try {
          if (validateSolution(PLACEHOLDER_FN_NAME(a, b),expected)) {
              "PASSED"
          } else{
              "FAILED"
          }
      }catch{
          case e: Exception => {e.getClass.getName}
      }
  
  }
  object QuestionEvaluator extends App {
  
      println(s"TEST-0...${driver(
        4, 33, 
        132    
      )}")   
  
  
      println(s"TEST-1...${driver(
        36, 67, 
        2412    
      )}")   
  
  
      println(s"TEST-2...${driver(
        65, 52, 
        3380    
      )}")   
  
  
      println(s"TEST-3...${driver(
        55, 37, 
        2035    
      )}")   
  
  
      println(s"TEST-4...${driver(
        35, 76, 
        2660    
      )}")   
  
  
      println(s"TEST-5...${driver(
        69, 98, 
        6762    
      )}")   
  
  
      println(s"TEST-6...${driver(
        84, 62, 
        5208    
      )}")   
  
  
      println(s"TEST-7...${driver(
        5, 80, 
        400    
      )}")   
  
  
      println(s"TEST-8...${driver(
        15, 36, 
        540    
      )}")   
  
  
      println(s"TEST-9...${driver(
        67, 84, 
        5628    
      )}")   
  
  }
  
source_py: def fast_multiplication_method_without_using_multiplication_operator_russian_peasants_algorithm(a, b):
      res = 0
      while (b > 0):
          if (b & 1):
              res = (res + a)
          a = (a << 1)
          b = (b >> 1)
      return res
source_cpp: unsigned int fast_multiplication_method_without_using_multiplication_operator_russian_peasants_algorithm(unsigned int a, unsigned int b) {
    int res = 0;
    while ( b > 0 ) {
      if ( b & 1 ) res = res + a;
      a = a << 1;
      b = b >> 1;
    }
    return res;
  }