Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

This is for Joyce Farrell's book Microsoft visual c# 2015: an introduction to object oriented programming 6th edition page 349 PE 2. This is what

This is for Joyce Farrell's book Microsoft visual c# 2015: an introduction to object oriented programming 6th edition page 349 PE 2.

This is what I have so far. I'm trying to figure out the part where it says "if an entry is not an integer, reprompt the user." I tried doing int.TryParse(fillint[x], out exceptionHand) but it wouldn't take the array. I'd like to create a while loop that reprompts the user. I also am having difficulty figuring out how to "call a second method that accepts out parameters for the highest value in the array, lowest value in the array, sum of the values in the array, and arithmetic average." Any help would be greatly appreciated. This is for self study not school work.

using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using static System.Console;

namespace sandbox1.cs { class Program { static void Main(string[] args) { int[] intArray = new int[20]; fillIntArray(intArray);

} private static void fillIntArray(params int[] fillInt) { int exceptionHand; WriteLine("Enter up to 20 values or type 'y' or 'n' to stop"); for (int x = 0; x < 20; x++) { fillInt[x] = Convert.ToInt32(ReadLine()); WriteLine(fillInt[x]); }

}

} }

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Data And Databases

Authors: Jeff Mapua

1st Edition

1978502257, 978-1978502253

More Books

Students also viewed these Databases questions

Question

3. How would you address the problems that make up the situation?

Answered: 1 week ago