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
Bess [88]
3 years ago
6

The program is to be answered in Java Programming not C++ Please answer the following: Modify the BarChart program to accept the

number of points scored by each player in a season. The bar chart displays one asterisk for each 10 points scored by a player. For example, if a player has scored 48 points, then display four asterisks.
Computers and Technology
1 answer:
Solnce55 [7]3 years ago
6 0

Answer:

import java.util.Scanner;

public class BarChart {

public static void main(String[] args) {

Scanner sc=new Scanner(System.in);

//take input from user

System.out.println("Enter Score");

int score=sc.nextInt();

int count=score/10;

int i=1;

//print horizontal bar

//if you want to print vertical bar then simply change into print which is replace by println

while(i<=count)

{

System.out.print("*");

i++;

}

}

}

Explanation:

You might be interested in
Find the area of the regular hexagon below by using the area formula for triangles.
mojhsa [17]
I think the answer is B. Because if you multiply 6x8 it’s 48 divided by 2 equals 24
5 0
3 years ago
Software for creating animations
Lady_Fox [76]
There´s PowToon, GoAnimate, ToonBoom. There are more, but these are the ones that I know about. I hope that I helped. Have a good day!

8 0
3 years ago
Read 2 more answers
What is the recommended secure protocol for voice and video applications? secure real-time transport protocol (srtp) hypertext t
snow_tiger [21]
The recommended secure protocol for voice and video applications is the Secure<span> Real-time Transport </span>Protocol<span> (SRTP) protocol. SRTP is a Real-time Transport </span>Protocol (RTP) profile used to  to provide encryption, message authentication and integrity.
The default cipher of SRTP is the Advanced Encryption Standard<span> (AES) .</span>
8 0
3 years ago
What is the Is option that prints the author of a file​
sleet_krkn [62]

Answer:

Print.. is your answer...

4 0
3 years ago
A year in the modern Gregorian Calendar consists of 365 days. In reality, the earth takes longer to rotate around the sun. To ac
GREYUIT [131]

Answer:

import java.util.Scanner;

public class LabProgram {

  public static void main(String[] args) {

      Scanner scnr = new Scanner(System.in);

      int inputYear;

      boolean isLeapYear;

      isLeapYear = false;

      inputYear = scnr.nextInt();

      // If a year is divisible by 400,  then it is a leap year

      if (inputYear % 400 == 0)

          isLeapYear = true;

      // If a year is divisible by 100,  then it is not a leap year

      if (inputYear % 100 == 0)

          isLeapYear = false;

      // If a year is divisible by 4,  then it is a leap year

      if (inputYear % 4 == 0)

          isLeapYear = true;

      if(isLeapYear)

          System.out.println(inputYear + " is a leap year.");

      else

          System.out.println(inputYear + " is not a leap year.");

  }

}

Explanation:

  • Take the year as an input from user and store it to inputYear variable.
  • If the year is a century year, check if the year is divisible by 400 ( the year must be evenly divisible by 400 ),  then set the boolean isLeapYear to true. If a year is divisible by 100,  then set the boolean isLeapYear to false. If a year is divisible by 4,  then set the boolean isLeapYear to true.
  • Check if isLeapYear is true, then print that it is a leap year. Otherwise, print that it is not a leap year.

Output:

1712

1712 is a leap year.

4 0
3 years ago
Read 2 more answers
Other questions:
  • Music voice and sound effects can all be recorded and stored on a computer as
    15·1 answer
  • Holly Carpenter argues that technology may actually prevent some kinds of evolution that would benefit humans. Do you agree with
    8·2 answers
  • Alison wants to add her company name at the bottom of every page in her document. Which option should she use?
    11·2 answers
  • _______ data would be useful for creating a report containing last year's revenue, which won't be changing.      A. Integrated B
    12·1 answer
  • Which of the following is a narrative essay most like?
    10·2 answers
  • What should be used to clean LCD monitors? Liquid window cleaner Ammonia wipes Windshield washer liquid Antistatic monitor wipes
    15·1 answer
  • ) Which is true about the agile method?
    7·1 answer
  • Kim is creating a PowerPoint
    13·1 answer
  • You have four DCs in your domain. Active Directory appears to be corrupted on one of the DCs, and you suspect a failing hard dri
    5·1 answer
  • outline 4 IDE features that makes software development much faster and more convenient than other alternatives.​
    9·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!