Получи случайную криптовалюту за регистрацию!

Can you create a function in C# which can accept varying numbe | C# 1001 notes

Can you create a function in C# which can accept varying number of arguments?

By using the params keyword, you can specify a method parameter that takes a variable number of arguments. No additional parameters are permitted after the params keyword in a method declaration, and only one params keyword is permitted in a method declaration. The declared type of the params parameter must be a single-dimensional array.