Use two-dimensional array in javascript to solve problem

Assignment Help Programming Languages
Reference no: EM1363176

Using javascript. Use a two-dimensional array to solve the following problem: A company has four salespeople (1 to 4) who sell five different products (1 to 5). Once a day, each salesperson passes in a slip for each type of product sold. Each slip contains the following:

a. The salesperson number

b.The product number

c.The total dollar value of that product sold that day

Thus, each salesperson passes in between 0 and 5 sales slips per day. Assume that the information from all the slips for last month is available. Write an application that will read all this information for last month's sales and summarize the total sales by salesperson and by product. All totals should be stored in the two-dimensional array sales. After processing all the information for last month, display the results in tabular format, with each column representing a particular salesperson and each row representing a particular product. Cross-total each row to get the total sales of each product for last month. Cross-total each column to get the total sales by salesperson for last month. Your tabular output should include these cross-totals to the right of the totaled rows and to the bottom of the totaled columns.

Reference no: EM1363176

Questions Cloud

Describe the shape of the average total cost function : Describe the shape of the average total cost function and also label the minimum point on the curve.
Question related to business management scenario : Question related to Business Management Scenario - definition of "race" specified in the statutory language of Title VII includes the following racial categories
Solvency and liquidity problems : Choose a publicly held company. Look at the most recent Income Statement, Balance Sheet, and Statement of Cash Flows and decide if you will give this company a loan equal to 10 percent of their retained earnings.
Explain company profit not determined without information : In the short run the typical company increases its output but its total cost also rises. Hence, the effect on the company 's profit cannot be determined without more information.
Use two-dimensional array in javascript to solve problem : Using javascript. Use a two-dimensional array to solve the following problem: A company has four salespeople (1 to 4) who sell five different products (1 to 5).
Developing a health promotion program or initiative : Imagine that you work with children with special needs and are tasked with developing a health promotion program/initiative there.
Explain and create a work breakdown structure : Explain and Create a Work Breakdown Structure (WBS) for building a two-story vinyl-sided home with 3 bedrooms and 2 bathrooms
Favorable or unfavorable variance : Sampson Apparel Incorporated incurred actual variable overhead expenses of $62,000 in the current year for the production of 10,000 units.
Implement a new performance management program : Prepare a memo to the Board describing what actions must be taken before the performance management program can be effectively implemented.

Reviews

Write a Review

Programming Languages Questions & Answers

  Create a new console application project

Create a new console application project and name it "Week1Lab_BirdN". Create the necessary member functions that will perform the required operations outlined in the lab summary above.

  Create child processes

Create child processes

  C program to accept three numbers inputs by user

Write down C program to accept three numbers input by a user, and outputs a table of temperatures in Fahrenheit, Celsius, and Kelvin.

  Generate an object-oriented design for a system

Generate an object-oriented design for a system that keeps tracks of your CD and DVD collection. Identify each of the classes, associated data, and operations for the classes.

  Create class uses element array of digits to store integers

Create a class HugeInteger which uses a 40-element array of digits to store integers as large as 40 digits each. Provide methods input, output, add and subtract.

  Write program-compute average using floating-point numbers

Write a program that will accept as input between 2 and 25 numbers and then calculate the average of the numbers. Make sure you use floating-point numbers in case the average is not a whole number.

  Create program to produce a summary of amounts due

Create a program that will produce a summary of the amounts due for Pat's Auto Repair Shop. Display a splash screen first, then display the Job Information Form.

  Technical project: sample website project

Technical Project: Sample Website Project , This assignment consists of three (3) sections: a narrative, a storyboard, and a business Website. You must submit all three (3) sections for the completion of this assignment.

  Design program to ecode message using caesar cypher

Design a program which decodes messages. Messages will be encoded using Caesar cypher, with each letter being decoded by replacing it with previous letter in alphabet.

  Program to calculate integer part of quotient

Calculate the integer part of the quotient when integer a is divided by integer. Calculate the integer remainder when integer a is divided by integer b

  Program to generate a random number between a range

Write down a program to generate random number between 1 and 100 and asks user to guess what number is.

  Determine total cost of order-display it in alert dialog box

After you determine the total cost of the order (purchase plus shipping and handling), display it in an alert dialog box.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd