title: Check If A Number Is Jumbled Or Not
signature: def checkIfANumberIsJumbledOrNot(num: Int) = {
test_code: import scala.collection.mutable.HashMap
  import scala.collection.immutable.HashSet
  
  
  // SOLUTION CODE
  // ============================================
  PLACEHOLDER_CODE_BODY
  
  
  // TESTING CODE 
  // ============================================
  def validateSolution(actual: Boolean , expected: Boolean): Boolean = {
      actual.toString == expected.toString
  }
  
  def driver(num: Int, expected: Boolean): String = {
      try {
          if (validateSolution(PLACEHOLDER_FN_NAME(num),expected)) {
              "PASSED"
          } else{
              "FAILED"
          }
      }catch{
          case e: Exception => {e.getClass.getName}
      }
  
  }
  object QuestionEvaluator extends App {
  
      println(s"TEST-0...${driver(
        67, 
        true    
      )}")   
  
  
      println(s"TEST-1...${driver(
        77, 
        true    
      )}")   
  
  
      println(s"TEST-2...${driver(
        35, 
        false    
      )}")   
  
  
      println(s"TEST-3...${driver(
        79, 
        false    
      )}")   
  
  
      println(s"TEST-4...${driver(
        45, 
        true    
      )}")   
  
  
      println(s"TEST-5...${driver(
        22, 
        true    
      )}")   
  
  
      println(s"TEST-6...${driver(
        68, 
        false    
      )}")   
  
  
      println(s"TEST-7...${driver(
        17, 
        false    
      )}")   
  
  
      println(s"TEST-8...${driver(
        5, 
        true    
      )}")   
  
  
      println(s"TEST-9...${driver(
        85, 
        false    
      )}")   
  
  }
  
source_py: def check_if_a_number_is_jumbled_or_not(num):
      if ((num // 10) == 0):
          return True
      while (num != 0):
          if ((num // 10) == 0):
              return True
          digit1 = (num % 10)
          digit2 = ((num // 10) % 10)
          if (abs((digit2 - digit1)) > 1):
              return False
          num = (num // 10)
      return True
source_cpp: bool check_if_a_number_is_jumbled_or_not(int num) {
    if ( num / 10 == 0 ) return true;
    while ( num != 0 ) {
      if ( num / 10 == 0 ) return true;
      int digit1 = num % 10;
      int digit2 = ( num / 10 ) % 10;
      if ( abs ( digit2 - digit1 ) > 1 ) return false;
      num = num / 10;
    }
    return true;
  }