int[] number = { 1, 2, 3, 4, 5 };var result = number.Select(n => n * 10);foreach (var item in result){Console.WriteLine(item);}
class Program{static void Main(string[] args){int[] mynumber = { 1,2,3,4,5,6,7,8,9,10};mynumber = mynumber.Select(b => b * 10).ToArray();for (int i = 0; i < 10; i++){Console.Write(mynumber[i]);Console.WriteLine();}Console.ReadKey();}}
int[] multiply = new int[] { 1, 2, 3, 4, 5, 6 }; IEnumerable result = multiply.Select(n => n * 10); foreach (int n in result) { Console.Write(n + “; “); }
void MultiplyElements(IList elements, int by) {elements.ForEach(e => e*by); }
class Program{static void Main(string[] args){int[] a = { 10,20,30,40,50 };var res = from i in a select i * 10;foreach (var r in res){Console.WriteLine(r);}Console.ReadKey();}}