Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

PLEASE DO IN JAVA! 4. (20 points) Spreadsheets can be stored in a format called Comma Separated Values (CSV). The spreadsheet below: Profit 42 581

image text in transcribed

PLEASE DO IN JAVA!

4. (20 points) Spreadsheets can be stored in a format called Comma Separated Values (CSV). The spreadsheet below: Profit 42 581 492 Date Item Bungee Light Horn 249 1642 1193 1/21/19 1/26/19 Would look like this in a CSV file (remember that newline characters are invisible) Date, Item, Cost, Profit, 1/7/19, Bungee, 249, 42, 1/21/19,Light, 1642,581, 1/26/19, Horn, 1193,492, CSV files are handy because they can exchange data between applications. For example, we use CSV files to move the grades from Zyante into Canvas. Notice there is a space both before and after the commas and that the cost and profit are stored as integral values Write a code fragment that will calculate the total profit from a CSV file from the keyboard, formatted like the one above, which contains three items. Do not assume the data is identical to that above. Remember that reading input is sequential-i.e. to get to the last thing in a row, you have to go through everything to the left. The trick to doing this successfully is to read in the values that you do not need to get to the ones that you do need

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

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

Students also viewed these Databases questions