C# Passing Array to FunctionIn C#, to reuse the array logic, we can create function. To pass array to function in C#, we need to provide only array name. C# Passing Array to Function Example: print array elementsLet's see an example of C# function which prints the array elements. Output: Printing array elements: 25 10 20 15 40 50 Printing array elements: 12 23 44 11 54 C# Passing Array to Function Example: Print minimum numberLet's see an example of C# array which prints minimum number in an array using function. Output: Minimum element is: 10 Minimum element is: 11 C# Passing Array to Function Example: Print maximum numberLet's see an example of C# array which prints maximum number in an array using function. Output: Maximum element is: 50 Maximum element is: 64
Next TopicC# Multidimensional Arrays
|