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, 22.06.2019 08:00
What is the algorithm for building a binary tree program
Answers: 2
question
Computers and Technology, 22.06.2019 10:30
Dave has to create animations for a game. which tool can dave use?
Answers: 3
question
Computers and Technology, 23.06.2019 11:30
The most accurate readings that you can take on an analog vom are when the meter's pointer is at the a. center scale. b. extreme right. c. near right. d. extreme left.
Answers: 1
question
Computers and Technology, 23.06.2019 19:00
Acompany is hiring professionals for web designing. the firm is small with few resources. they want employees who possess problem-solving skills and can independently carry out responsibilities. which kind of employee should they select?
Answers: 2
You know the right answer?
An array of integers named parkingtickets has been declared and initialized to the number of parking...
Questions
question
Mathematics, 25.01.2021 02:10
question
Spanish, 25.01.2021 02:10
Questions on the website: 13722360