1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Vanyuwa [196]
3 years ago
7

How do you do this question?

Computers and Technology
1 answer:
elena55 [62]3 years ago
4 0

Answer:

for (scores.Entry<String, Integer> entry : scores.entrySet()) {

          int value=0; String key="Rambo";

          String k = entry.getKey();

           int v = entry.getValue();

           if (v>value)

           {

               value =v;

           }

           else

           {

               value=value;

           }  

       }

       for( scores.Entry<String, Integer> entry : scores.entrySet())

      {

        if( entry.getValue()==value)            

        System.out.println("Key = " + entry.getKey() + ", Value = " + entry.getValue());

      }

Explanation:

The above scores are an object of Map type.  And this is a parameter of findUopStudent function. So scores is a Map, and entry is an item. And we get its key and value. Now we compare each value using senteniel method and find the maximum value. Now we iterate through the scores using for the look and check the value of each entry against the maximum value found, and we print out the entry with maximum value. And that is the top student, which is required.  

You might be interested in
The process of searching for a special pattern of symbols within a larger collection of information is called pattern ____.
tatuchka [14]

Answer:

Pattern Matching

Explanation:

Pattern matching in computer science is defined as the analysing & finding specific sequences of data of some pattern among raw data or a sequence of tokens.

4 0
3 years ago
PLEASE HELP WILL MARK BRAINLIEST
Sergeeva-Olga [200]
I believe it’s boundaries
3 0
2 years ago
Read 2 more answers
Make The PYTHON Code<br><br> print first 3 character of a string - given "Seattle" expected "Sea"
vlada-n [284]

This program uses a conditional to determine if seafood is safe to consume.

IF (seafood = "mollusk" OR daysFrozen ≥ 7) { rating ← "safe" } ELSE { rating ← "unsafe" }

In which situations will rating be "safe"?

️Note that there may be multiple answers to this question.

Choose all answers that apply:Choose all answers that apply:

1. When sea food is mollusk and day frozen is 1

2.When sea food is mollusk and day froze is 9

3. When see food salmon and day frozen is 7

<em>Did that help?</em>

6 0
2 years ago
Which is a good technique for effectively proofreading your presentation?
laiz [17]
Read it backwords. it helps look for spelling errors.
7 0
3 years ago
A(n) ____ is a collection of one or more program statements combined to perform some action
finlep [7]

The answer is Method

A method is a code block of statements that perform a task. By calling a method, a program causes statements to be executed. In C# programming, every instruction that is executed is performed in the context of a method. Technically, it is how behaviors are implemented in C# and are enclosed in parentheses separated by commas






3 0
3 years ago
Other questions:
  • Q3** Write a query to create a new price list for books written by the same author. Allow the user to enter only the first 4 let
    15·1 answer
  • Write a program that assigns two integer values from standard input to the variables int1 and int2, then prints "true" if they a
    10·1 answer
  • Suppose your friend, who is a small business owner, wants to computerize her business functions such as accounting, payroll, and
    7·1 answer
  • Which one of these variables has an illegal name?
    11·1 answer
  • Under the assumption that there exists an unknown Turing machine encodableinc1bits that decides3-SATis inO(n10) time, give imple
    7·1 answer
  • Seth is considering advertising his business using paid search results.What do you think makes paid search advertising so effect
    11·2 answers
  • SATCOM in the Ku- and Ka- bands, as well as EHF systems are adversely affected by rain (the higher the frequency, the greater th
    14·1 answer
  • A video game controller contains the buttons: A, B, X, Y. When the player presses A their character Jumps. When the player press
    15·1 answer
  • Help pweeze this is due today :(<br><br> I will give u brainliest just pweeze, I need this answer :(
    8·1 answer
  • FoRWarD MaRcH AND hERe We Go MEMbers of the agEncy BaKuGO AHHHHHHHHH-
    10·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!