int inp = 4; int term = 9; int temp = term; int total = term; for(int i=0; i<inp; i++) { temp *= 10; temp += term; Console.WriteLine($"current={total}; next={temp}"); total += temp; }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)