Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Develop a C# console application that implements three arrays; a string array initialized with exactly the following five data items { Widget 15.50, Thingy 50.99,

Develop a C# console application that implements three arrays; a string array initialized with exactly the following five data items { "Widget 15.50", "Thingy 50.99", "Ratchet25.00", "Clanger115.49", "Fracker75.25" }, a string array to hold the five part names to be parsed from the previously detailed string array, an array of five double value prices to be parsed from the previously mentioned array. Create a void method that will accept as arguments the two arrays of strings and the array of doubles when called from Main. In the method you will access the five members of the first string array mentioned above and you will parse out the name portion of each string element (first 7 bytes), assigning the string value to the corresponding element in the array of names. In the method you will also parse out the numeric portion of each string and assign it to the corresponding element of the price array. The parsing should be done using the string method SubString. In Main, after calling the parsing method you will display the elements of both the array of names and the array of prices side-by-side (do not display the array from which you parsed the data items). The output should look something like this: Widget $15.50 Thingy $50.99 Ratchet $25.00 Clanger $115.49 Fracker $75.25 Press any key to continue . . .

Step by Step Solution

3.47 Rating (150 Votes )

There are 3 Steps involved in it

Step: 1

namespaces using System using SystemCollectionsGeneric using SystemLin... 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

Step: 3

blur-text-image

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

Mobile Communications

Authors: Jochen Schiller

2nd edition

978-0321123817, 321123816, 978-8131724262

More Books

Students also viewed these Programming questions

Question

Examine various types of executive compensation plans.

Answered: 1 week ago

Question

1. What is the meaning and definition of banks ?

Answered: 1 week ago

Question

2. What is the meaning and definition of Banking?

Answered: 1 week ago

Question

3.What are the Importance / Role of Bank in Business?

Answered: 1 week ago

Question

How do inclination and elevation determine the use of a satellite?

Answered: 1 week ago