subject

An array of integers named parkingtickets has been declared and initialized to the number of parking tickets given out by the city police each day since the beginning of the current year. (thus, the first element of the array contains the number of tickets given on january 1; the last element contains the number of tickets given today.)a variable named ndays has been declared and initialized to hold the size of the array . (thus, if today were january 18, ndays would have the value 18; if today were february 3, ndays would have the value 34.)in addition, a variable named mosttickets has been declared , along with a variable k. without using any additional variables , and without changing the values of ndays or the elements of the parkingtickets array , write some code that results in mosttickets containing the largest value found in parkingtickets. mosttickets=0; for (k=0; k< ndays; k++){if (parkingtickets[k]> mosttickets) mosttickets=parkingtickets[k]; }

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 13:00
What converts chemical energy into rotational or linear motion?
Answers: 1
question
Computers and Technology, 21.06.2019 17:30
How many pairs of chromosomes do human body cells contain?
Answers: 2
question
Computers and Technology, 22.06.2019 02:00
Aisha has finished working on a word processing document that contains 15 pages. she has added some special elements in the first three pages, page 9 and 10, and page 15 from the document. she wants to print only these pages to see how they look. which option is the correct way to represent (in the print dialog box) the pages that aisha wants to print?
Answers: 1
question
Computers and Technology, 22.06.2019 10:30
You have a large, late-model pick-up truck with a rear seat. the pick-up truck weighs 6,500 pounds. the florida seat belt law
Answers: 1
You know the right answer?
An array of integers named parkingtickets has been declared and initialized to the number of parking...
Questions
question
Mathematics, 09.06.2021 19:00
question
Mathematics, 09.06.2021 19:00
question
Mathematics, 09.06.2021 19:00
question
Mathematics, 09.06.2021 19:00
question
Mathematics, 09.06.2021 19:10
question
Mathematics, 09.06.2021 19:10
Questions on the website: 13722362