title: Count Strings Can Formed Using B C Given Constraints 1
signature: pub fn count_strings_can_formed_using_b_c_given_constraints_1(n: i32) -> i32 {
test_code: use std::collections::HashMap;
  use std::collections::HashSet;
  use std::cmp::*;
  use std::collections::*;
  use std::fmt::*; 
  
  
  // SOLUTION CODE
  // ============================================
  PLACEHOLDER_CODE_BODY
  
  // TESTING CODE 
  // ============================================
  pub fn validate_solution(actual: i32, expected: i32)->bool{
  return actual==expected
  }
  pub fn driver(n: i32, expected: i32)->String{
      if validate_solution(PLACEHOLDER_FN_NAME(n), expected) {
        return "PASSED".to_string();
      };
      return "FAILED".to_string();
  
  }
  
  fn main() {
      println!("TEST-0...{}", driver(
        55, 
        83271
      ));
      
      println!("TEST-1...{}", driver(
        36, 
        23383
      ));
      
      println!("TEST-2...{}", driver(
        69, 
        164359
      ));
      
      println!("TEST-3...{}", driver(
        92, 
        389483
      ));
      
      println!("TEST-4...{}", driver(
        73, 
        194619
      ));
      
      println!("TEST-5...{}", driver(
        16, 
        2073
      ));
      
      println!("TEST-6...{}", driver(
        88, 
        340869
      ));
      
      println!("TEST-7...{}", driver(
        19, 
        3459
      ));
      
      println!("TEST-8...{}", driver(
        66, 
        143848
      ));
      
      println!("TEST-9...{}", driver(
        68, 
        157319
      ));
      
  }
source_py: def count_strings_can_formed_using_b_c_given_constraints_1(n):
      return ((1 + (n * 2)) + ((n * ((n * n) - 1)) // 2))
source_cpp: int count_strings_can_formed_using_b_c_given_constraints_1(int n) {
    return 1 + ( n * 2 ) + ( n * ( ( n * n ) - 1 ) / 2 );
  }