I have an array of strings like this:
test[1] = "AA";
test[2] = "BB";
I like to do things in good ways. Now I need to iterate through the array so it looks like this:
1. "AA"
2. "BB"
etc ..
I think I can do this with a for loop and index but I am wondering if I can also do it with LINQ.
forloop.forloop:for (int i = 0; i < arr.Length; i++) arr[i] = string.Format("{0}. {1}", i+1, arr[i]);. It's all good if you are simply learning how to use LINQ, but sometimes there is nothing wrong with the basics...