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
Paha777 [63]
4 years ago
6

import java.util.Scanner; public class TeenagerDetector { public static void main (String [] args) { Scanner scnr = new Scanner(

System.in); boolean isTeenager; int kidAge; kidAge = scnr.nextInt(); /* Your solution goes here */ if (isTeenager) { System.out.println("Teen"); } else { System.out.println("Not teen"); } } }

Computers and Technology
2 answers:
Sonja [21]4 years ago
5 0

Answer:

import java.util.Scanner;

public class TeenagerDetector {

   public static void main (String [] args) {

       Scanner scnr = new Scanner(System.in);

       boolean isTeenager;

       int kidAge;

       kidAge = scnr.nextInt();

       

       /* Your solution goes here */

       isTeenager = (kidAge >= 13) && (kidAge <= 19);

       if (isTeenager) {

           System.out.println("Teen");

           

       } else { System.out.println("Not teen"); } } }

Explanation:

A condition which check for the teenager age and return a boolean is assigned to isTeenager.

isTeenager = (kidAge >=13) && (kidAge <= 19);

So, if the kidAge is greater than/equal to 13 and less than/19, the boolean isTeenager will be true and the program will output "Teen" else "false" will be output.

The range of age for a teenager is 13 - 19.

Virty [35]4 years ago
5 0

Answer:

isTeenager = ( kidAge >= 13 ) && ( kidAge <= 19);

Explanation:

You might be interested in
The purpose of the ________ element is to describe the contents of a table.
Korolek [52]
<caption> element.

It is used to add a caption to a HTML table. With CSS, it may be positioned right at the bottom of the table but in HTML, it must appear as the 1st descendant of a parent <table>. Note that you can specify only one caption in a single table.






4 0
3 years ago
What do you use for soaking hands and holding soapy water​
sertanlavr [38]

Answer

???

Explanation:

Was this a school question?

5 0
3 years ago
Read 2 more answers
* Declare a variable called "race" of type "Race", andinitialise its value to a new instance of the "Race" class. The"Race" cons
goldfiish [28.3K]

Answer:

Race race = new Race(track, car);

Explanation:

Complete code fragment is as follows:

Track track = new Track();

Car car = mycar;

Race race = new Race(track,car);

Here we are declaring a variable race of the type Race  which is initialized to new instance of Race class. The constructor of race takes up the following 2 arguments:

1) New Instance of Track class;

2) Previously defined reference to an object of type Car.

4 0
4 years ago
Which tag denotes the end of an element in HTML?
goldenfox [79]

Answer:

A. /

Explanation:

When creating a line in HTML, you start with a <ELEMENT> <em>ENTER TEXT</em> </ELEMENT>

Example:

<title> Mark me brainliest! <<u>/</u>title>

<u><em>Hope this helps!</em></u>

<em>-Isa</em>

7 0
3 years ago
1.
Umnica [9.8K]

Answer:

B

Explanation:

trust

7 0
3 years ago
Other questions:
  • The mass of a textbook is about 1.25 kilograms. Aproximately, how many ounces is this?
    10·1 answer
  • Excel attempts to guess which cells you want to include in the function by looking for ranges that are adjacent to the selected
    13·1 answer
  • Edhesive 4.1 question 1
    9·1 answer
  • Hey! Would you please help me do this program?
    14·1 answer
  • Write a SELECT statement that returns the same result set as this SELECT statement, but don’t use a join. Instead, use a subquer
    12·1 answer
  • The UML models operations by listing the operation name preceded by an access modifier. A(n) ________ indicates a public operati
    7·2 answers
  • Write a C++ program that would take 10 integers and outputs mean, median, and range. Create at least three functions: one for so
    7·1 answer
  • You want to receive alerts if unusual activity is detected relating to the Web servers deployed in your perimeter network. What
    7·1 answer
  • Long Answer Questions: a. Briefly explain the types of Control Structures in QBASIC.​
    5·1 answer
  • What is the destination ip address when an ipv4 host sends a dhcpdiscover message?
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!