Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C# programming language please help me with this assignment,I'm not allowed to use any collections and library to solve .I have to use just simple

C# programming language

please help me with this assignment,I'm not allowed to use any collections and library to solve .I have to use just simple and complex algorithms.

image text in transcribed

At Christmas the reindeer trips were registered. We know the number of reindeers, and for each of them how many trips happened and how long was a trip (in miles). Write a program that determines the followings: 1. How many trips were exactly 40 miles? 2. Which reindeer travelled the most? 3. How many reindeers and which one (with index) travelled more than M miles? 4. Did it happen, that a reindeer travelled less than another one shortes trip? Input The first line of the standard input contains the number of Reindeers (1N1000), and the given M number (1M2000). Afterward, there are N lines, one line for each Reindeer. Each line contains the number of steps (1R1000) that was packed by the given Elf, it is followed by R integers those mean the number of gifts in the rucksacks (1G2000). Output You have to write exactly 4 lines into the standard output. Each line must contain an answer for the given question in the given order. First line contains a number, the number of trips that were exaclty 40 miles. The second line contains the index of the reindeer who travelled the most. The third line contains the number of the reindeer and their indexes separated by space. The last, fourth line contains YES or NO that answers the fourth question. wnuman 12s, because the first reindeer travelled 50 miles and the last reindeer shortest trip is 53

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