public static void Main()
Console.WriteLine(GetAccountNumberFromCbu("1231231231231231231231"));
public static string GetAccountNumberFromCbu(string cbu)
if (cbu != null && cbu.Length == 22)
return Int32.Parse(cbu.Substring(3, 4)) + "-" + Int32.Parse(cbu.Substring(12, 8)) + "-" + cbu.Substring(20, 1);