Question: c# Create a static method named CreateStringArray() that takes in 3 strings as parameters. The method should make a new string[]. Next the method should

c# Create a static method named CreateStringArray() that takes in 3 strings as parameters. The method should make a new string[]. Next the method should add each string into its own spot in the string[] and finally return the string[].

Create a static method named SumArray() that takes in an int[] as a parameter. The method should add all of the values in the array together and return the sum.

Create a static method named RemoveNum() that takes in two parameters: a List of numbers (int) and a number (int).

Check to see if the List contains the number parameter that was passed into the method. If so, remove that value from the list. (Note: Because youll be modifying the original list passed in, simply return void.)

Create a static method named AddToList() that takes in a string parameter. The method should add the strings grapes, oranges, and the string parameter to a List of strings. Return the updated List of strings. For example, if "cherries" is passed as a parameter, the method will return a list of "grapes", "oranges", "cherries".

Create a static method named TryMe() that takes in two number (int) parameters. The method should divide the first parameter by the second parameter and return 9 if there is an Arithmetic Exception. If there is no error, return the correct result from the operation.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!