title: Triangular Matchstick Number
signature: def triangularMatchstickNumber(x: Int) = {
test_code: import scala.collection.mutable.HashMap
  import scala.collection.immutable.HashSet
  
  
  // SOLUTION CODE
  // ============================================
  PLACEHOLDER_CODE_BODY
  
  
  // TESTING CODE 
  // ============================================
  def validateSolution(actual: Float , expected: Float): Boolean = {
      (actual - expected).abs < 1e-06F
  }
  
  def driver(x: Int, expected: Float): String = {
      try {
          if (validateSolution(PLACEHOLDER_FN_NAME(x),expected)) {
              "PASSED"
          } else{
              "FAILED"
          }
      }catch{
          case e: Exception => {e.getClass.getName}
      }
  
  }
  object QuestionEvaluator extends App {
  
      println(s"TEST-0...${driver(
        6, 
        63.0F    
      )}")   
  
  
      println(s"TEST-1...${driver(
        25, 
        975.0F    
      )}")   
  
  
      println(s"TEST-2...${driver(
        15, 
        360.0F    
      )}")   
  
  
      println(s"TEST-3...${driver(
        30, 
        1395.0F    
      )}")   
  
  
      println(s"TEST-4...${driver(
        17, 
        459.0F    
      )}")   
  
  
      println(s"TEST-5...${driver(
        80, 
        9720.0F    
      )}")   
  
  
      println(s"TEST-6...${driver(
        27, 
        1134.0F    
      )}")   
  
  
      println(s"TEST-7...${driver(
        13, 
        273.0F    
      )}")   
  
  
      println(s"TEST-8...${driver(
        12, 
        234.0F    
      )}")   
  
  
      println(s"TEST-9...${driver(
        67, 
        6834.0F    
      )}")   
  
  }
  
source_py: def triangular_matchstick_number(x):
      return (((3 * x) * (x + 1)) / 2)
source_cpp: int triangular_matchstick_number(int x) {
    return ( 3 * x * ( x + 1 ) ) / 2;
  }