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
Rasek [7]
2 years ago
13

write a java program that prompts the user to enter scores (each number an integer from 0 to 10) and prints the following output

: how many scores entered the highest score the lowest score the average of all the scores the average with the highest and lowest score not counted if the user enters less than 3 scores print an error message instead of the output above
Computers and Technology
1 answer:
Vladimir [108]2 years ago
4 0

Answer:

Explanation:

The following is written in Java. It continues asking the user for inputs until they enter a -1. Then it saves all the values into an array and calculates the number of values entered, the highest, and lowest, and prints all the variables to the screen. The code was tested and the output can be seen in the attached image below.

import java.util.ArrayList;

import java.util.Arrays;

import java.util.Scanner;

class Brainly {

   public static void main(String[] args) {

       Scanner in = new Scanner(System.in);

       int count = 0;

       int highest, lowest;

       ArrayList<Integer> myArr = new ArrayList<>();

       while (true) {

           System.out.println("Enter a number [0-10] or -1 to exit");

           int num = in.nextInt();

           if (num != -1) {

               if ((num >= 0) && (num <= 10)) {

                   count+= 1;

                   myArr.add(num);

               } else {

                   System.out.println("Wrong Value");

               }

           } else {

               break;

           }

       }

       if (myArr.size() > 3) {

           highest = myArr.get(0);

           lowest = myArr.get(0);

           for (int x: myArr) {

               if (x > highest) {

                   highest = x;

               }

               if (x < lowest) {

                   lowest = x;

               }

           }

           System.out.println("Number of Elements: " + count);

           System.out.println("Highest: " + highest);

           System.out.println("Lowest : " + lowest);

       } else {

           System.out.println("Number of Elements: " + count);

           System.out.println("No Highest or Lowest Elements");

       }

   }

}

You might be interested in
What are the uses of a modem
Vlada [557]

Modem provides internet, WiFi, we can connect multiple devices to internet through modem.

Modem provides radiation of short wavelength and the transmitter in your mobile phones and computers convert those radiations into digital signals and vice-versa.

5 0
3 years ago
Escribe un ejemplo de:• Software de aplicación. • Software de diagnóstico. • Software de sistema. ayudenme plis, me toca entrega
Afina-wow [57]

Answer:

1. Software de aplicación: Microsoft Word.

2. Software de diagnóstico: Speccy.

3. Software de sistema: Windows operating system (OS).

Explanation:

Un software puede definirse como un conjunto de instrucciones ejecutables (códigos) o una colección de datos que se utiliza normalmente para instruir a una computadora sobre cómo realizar una tarea específica y resolver un problema en particular.

Básicamente, los softwares se clasifican en tres (3) categorías principales y estas son;

1. <u>Software de aplicación</u>: es un software de usuario final que normalmente está diseñado para realizar tareas y funciones específicas.

Algunos ejemplos de software de aplicación son Microsoft PowerPoint, Notepad, Windows Media player, Firefox, Go-ogle Chrome, Adobe Photoshop, AutoCAD, etc.

2. <u>Software de diagnóstico</u>: estos son programas de software que se utilizan para solucionar problemas y posiblemente reparar un sistema informático.

Algunos ejemplos de software de diagnóstico son Speccy, Windows Sysinternals Suite, System Explorer, hddscan, HWiNFO, SIW (System Information for Windows), CPU-Z, HD Tune, etc.

3. <u>Software de sistema</u>: es un software que normalmente está diseñado para ejecutar el hardware de la computadora y todas las demás aplicaciones de software.

Algunos ejemplos de software del sistema son Linux, Windows OS, Mac OS, WinZip, McAfee antivirus, Norton antivirus, Avast antivirus, Piriform CCleaner, Ubuntu, etc.

8 0
3 years ago
How many bits can a memory chip with the below configuration support? For full credit, show how you got the answer.
tatiyna

Answer:

Total Memory= 4 KB = 4096 bytes = 32768 bits

Explanation:

<em><u>1. Data lines are 8 From D0 to D7</u></em>

so

Total memory at single address locations is 8 bits.

<em><u>2. Address lines are 12 (A0 to A11)</u></em>

There are 12 address lines but 3 out 12 are for selction of chip or memory bank.

so only 9 pins are there to address the locations on one chip.

Total No. of address locations on single chip = 2^9 = 512 locations

as 1 location is 1 byte so total memory of single chip is 512 bytes.

<u><em>3. Total Memory Bank </em></u>

There are total 3 selection pins for memory bank.

so

Total chips = 2^3 = 8.

<em><u>4. Total Memory </u></em>

Total size of 1 chip = 512 bytes

Total size of 8 chip = 8x512 bytes = 4096 bytes = 4096/1024 kb = 4 kb

<em>So total memory of system is 4 Kb = 4096 bytes = 32768 bits</em>

5 0
3 years ago
How can a CRM system help communicate issues in the supply chain between customers and drones?
riadik2000 [5.3K]

Answer:

CRM system can help customers about the service supplied.  

Explanation:

CRM stands for Customer Relationship Management and CRM system is a useful tool for communicating with customers.

CRM can keep the data about the order provided by the customer and has updated info about its status.

For example, if the customer of a logistics company wants to know where his/her order is, customer represantative can give up-to-date info about the order where abouts. Or the customer directly uses web to check the status of the order.

All these service can be provided by a CRM system, since drones can send its location to CRM systems.

8 0
2 years ago
Which is the following is a valid email id<br><br>​
Minchanka [31]

Answer:

sorry there are no options available

6 0
2 years ago
Other questions:
  • Which of the following could be defined as a general-purpose computing device that enables workers to create, manage, store, sea
    12·1 answer
  • Assume that there is a class called BankAccountHolder that represents an individual member of a bank. There is also a BankAccoun
    5·2 answers
  • Implement function bin2dec that takes a binary number bin_num as a string argument and prints out the corresponding decimal numb
    9·1 answer
  • Please answer it’s timed
    11·1 answer
  • Explain four sitting postures in a computer laboratory​
    9·1 answer
  • Create a mobile app plan using PowerPoint slides to show mock-ups of screens,
    6·1 answer
  • What is smarta Art ? ​
    10·1 answer
  • When you save a presentation with a .potx file extension, which type of powerpoint file is created?
    8·1 answer
  • 8. Give regular expressions with alphabet {a, b} for
    6·1 answer
  • a benefit of cloud computing is scaling up or down as demand for your services increases or decreases. the word that is most ass
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!