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
tia_tia [17]
3 years ago
9

Write an if-else statement with multiple branches. If givenYear is 2101 or greater, print "Distant future" (without quotes). Els

e, if givenYear is 2001 or greater (2001-2100), print "21st century".
Computers and Technology
1 answer:
irga5000 [103]3 years ago
3 0

Answer:

import java.util.Scanner;

public class num9 {

   public static void main(String[] args) {

       Scanner in = new Scanner(System.in);

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

       int givenYear =in.nextInt();

       if(givenYear>=2101){

           System.out.println("Distant Future");

       }

       else if(givenYear>=2001){

           System.out.println("21st Century");

       }

   }

}

Explanation:

  • Using Java programming Language
  • Import Scanner class to receive user input of the variable givenYear
  • Use if statement to check the first condition if(givenYear>=2101)
  • Use else if statement to check the second condition if(givenYear>=2001)
  • print Distant future and 21st century respectively
You might be interested in
What is the output from main (below) after the following function is called. void calculateCost(int count, double& subTotal,
GalinKa [24]

Answer:

     

Explanation:

7 0
3 years ago
The act of illegally copying software, music,or movies that are copied protect?
miv72 [106K]
It’s protects piracy C
4 0
3 years ago
Read 2 more answers
Lori wants to set up a SOHO network in her apartment. The apartment comes with a Gigabit Ethernet network already installed. Lor
Yanka [14]

Connection to the gigabit ethernet network must be done with Cat6 Cable. Using the wireless ethernet router as the network device and connecting the cable to the printer must be done with Cat5e Cable.

We can arrive at this answer because:

  • The Cat6 Cable will be responsible for establishing a bridge between the gigabyte Ethernet and the network device, allowing data delivery to be made between the two systems.
  • This connection must be made with a wireless device, to keep it more stabilized and it needs, mainly, for the notebook to receive the internet signal. This will be done using the wireless ethernet router.
  • The printer needs a softer, less rigid connection, so a Cat5e cable will be a convenient option.

In this case, we can see that using these devices will allow Lori to have a more stable and efficient connection to meet her needs.

More information on network connection at the link:

brainly.com/question/8118353

5 0
2 years ago
Read 2 more answers
Ok can someone tell me why I can’t do this? I’m trying to put a video as my background but it won’t show up when I go to add vid
hram777 [196]

Answer: money

Explanation:

3 0
3 years ago
When researching Information about technology for use in a project, it is NOT important to consider the date that the informatio
REY [17]

Answer:

B. False

Explanation:

Hope this helps!

4 0
2 years ago
Other questions:
  • A customer service representative for an Internet provider uses various techniques to help a frustrated customer with a slow Int
    13·1 answer
  • The Internet and World Wide Web allow almost any business to be global. What are two important results of this process?
    8·1 answer
  • Which of the following economic systems leaves production decisions completely up to the producers?
    15·2 answers
  • Which of the following is a malicious program that can replicate and spread from computer to computer?
    13·2 answers
  • Which party controlled the White House and politics in the late 1800s, except for Grover
    6·2 answers
  • Computer programming is an essential skill for anyone wishing to pursue a career in cybersecurity. What might be a good ""first
    13·1 answer
  • How does leadership play a role in IT management? How does leadership need to be aligned to the company’s goals for IT managemen
    9·1 answer
  • In Java, Create a two part program. The first takes a user inputted number and lists the factors. The second, lists all the prim
    12·1 answer
  • What is the name of the arm that is attached to the read/write head?
    13·1 answer
  • Why are men more exposed to mass media?
    14·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!