comefrom: <garvit244>482_1.py
code: def licenseKeyFormatting( S, K):
      S = S.replace('-','').upper()
      result = ""
      
      if len(S)%K == 0:
          for index in range(0, len(S), K):
              result += S[index:index+K] + "-"
      else:
          result = S[:len(S)%K] + "-"
          for index in range(len(S)%K, len(S), K):
              result += S[index:index+K] + "-"
      return result[:-1]
masked: def sample_funcname ( var_0 , var_1 ) :
      var_0 = var_0.var_2 ( '-' , '' ).upper ( )
      var_7 = ""
      if len ( var_0 ) % var_1 == 0 :
          for var_11 in range ( 0 , len ( var_0 ) , var_1 ) :
              var_7 += var_0 [ var_11 : var_11 + var_1 ] + "-"
      else :
          var_7 = var_0 [ : len ( var_0 ) % var_1 ] + "-"
          for var_11 in range ( len ( var_0 ) % var_1 , len ( var_0 ) , var_1 ) :
              var_7 += var_0 [ var_11 : var_11 + var_1 ] + "-"
      return var_7 [ : - 1 ]
  