title: Google Case Given Sentence
signature: def googleCaseGivenSentence(s: String) = {
test_code: import scala.collection.mutable.HashMap
  import scala.collection.immutable.HashSet
  
  
  // SOLUTION CODE
  // ============================================
  PLACEHOLDER_CODE_BODY
  
  
  // TESTING CODE 
  // ============================================
  def validateSolution(actual: String , expected: String): Boolean = {
      actual.toString == expected.toString
  }
  
  def driver(s: String, expected: String): String = {
      try {
          if (validateSolution(PLACEHOLDER_FN_NAME(s),expected)) {
              "PASSED"
          } else{
              "FAILED"
          }
      }catch{
          case e: Exception => {e.getClass.getName}
      }
  
  }
  object QuestionEvaluator extends App {
  
      println(s"TEST-0...${driver(
        "TEYndweqZA", 
        "tEYNDWEQZA"    
      )}")   
  
  
      println(s"TEST-1...${driver(
        "01865", 
        "01865"    
      )}")   
  
  
      println(s"TEST-2...${driver(
        "11001100", 
        "11001100"    
      )}")   
  
  
      println(s"TEST-3...${driver(
        "CzwznJmQet", 
        "cZWZNJMQET"    
      )}")   
  
  
      println(s"TEST-4...${driver(
        "318305446", 
        "318305446"    
      )}")   
  
  
      println(s"TEST-5...${driver(
        "0000001111110", 
        "0000001111110"    
      )}")   
  
  
      println(s"TEST-6...${driver(
        "yzT", 
        "yZT"    
      )}")   
  
  
      println(s"TEST-7...${driver(
        "38630230", 
        "38630230"    
      )}")   
  
  
      println(s"TEST-8...${driver(
        "01101", 
        "01101"    
      )}")   
  
  
      println(s"TEST-9...${driver(
        "zoizI", 
        "zOIZI"    
      )}")   
  
  }
  
source_py: def google_case_given_sentence(s):
      n = len(s)
      s1 = ''
      s1 = (s1 + s[0].lower())
      i = 1
      while (i < n):
          if ((s[i] == ' ') and (i <= n)):
              s1 = ((s1 + ' ') + s[(i + 1)].lower())
              i = (i + 1)
          else:
              s1 = (s1 + s[i].upper())
          i = (i + 1)
      return s1
source_cpp: string google_case_given_sentence(string s) {
    int n = s . length ( );
    s [ 0 ] = tolower ( s [ 0 ] );
    for ( int i = 1;
    i < n;
    i ++ ) {
      if ( s [ i ] == ' ' && i < n ) {
        s [ i + 1 ] = tolower ( s [ i + 1 ] );
        i ++;
      }
      else s [ i ] = toupper ( s [ i ] );
    }
    return s;
  }