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
amid [387]
3 years ago
13

Write an expression that will cause the following code to print "I am a teenager" if the value of userAge is less than 20. Zyboo

ks won't let me edit any other line, and UserAge > 20 was marked wrong. It won't accept the ≥ symbol either.

Computers and Technology
1 answer:
VikaD [51]3 years ago
6 0

Answer:

Replace

if userAge > 20

with

userAge > 19

Explanation:

if userAge > 20  checks if age is 21, 22, 23, 24........

The else condition which prints "I am a teenager" checks if age is 20, 19, 18....

Notice that 20 is inclusive of the else condition; this shouldn't be because for userAge to be less than 20, 20 isn't inclusive

To solve this,

Replace if userAge > 20 with userAge > 19

So that, the else

The else condition which prints "I am a teenager" checks if age is 19, 18, 17, 16....

You might be interested in
How many bits does it take to store a 3-minute song using an audio encoding method that samples at the rate of 40,000 bits/secon
blondinia [14]

Answer:

115200000 bits

Explanation:

Given Data:

Total Time = 3 minute = 3 x 60 sec = 180 sec

Sampling rate = 40,000 bits / sample

Each sample contain bits = 16 bits /sample

Total bits of song = ?

Solution

Total bits of song = Total Time x Sampling rate x Each sample contain bits

                             = 180 sec x 40,000 bits / sec x 16 bits /sample

                             = 115200000 bits

                             =  115200000/8 bits

                             = 14400000 bytes

                             = 144 MB

There are total samples in one second are 40000. Total time of the song is 180 seconds and one sample contains 16 bits. so the total bits in the song are 144 MB.

5 0
3 years ago
The chart shows an example of a study-time survey. Students can use the formula shown in the survey to figure out ways to track
LUCKY_DIMON [66]
<span>how many hours they can work on a project.</span>
3 0
3 years ago
What is one common way to select a package name for a project?
Nastasia [14]

Answer:

Jeez idrk

Explanation:

Akkaqka

7 0
3 years ago
Argue whether we can infer anything about a candidate's ability to work in a professional environment based on his or her resume
nevsk [136]

Answer:

Candidates resume shows his way of presenting and organizing.

Explanation:

  • Resume formatting is an important part of a candidate's ability to work. In any professional environment, it's necessary to have a properly formatted resume.  
  • The resume formatting should be up to date with the latest information and data. The formatting involves the borders, headings, grammar, and spelling or typo errors, etc.  
  • But these mistakes can be easily avoided such as proofreading and removing unnecessary details and sloppy fronts.
5 0
2 years ago
Implement the function calcWordFrequencies() that uses a single prompt tonread a list of words (separated by spaces). Then, the
Morgarella [4.7K]
The function it puts those consoles
4 0
3 years ago
Other questions:
  • Which of these browsers was the first widely adopted?
    12·1 answer
  • The ____ aggregate function finds the largest value
    10·1 answer
  • Stating a document is PDF or XPS document refers to document _______​
    10·1 answer
  • Write the proghrams for the following:
    13·1 answer
  • Celeste is writing a paper. However, two pages in, her computer shuts down unexpectedly. She never saved her paper, and all her
    12·2 answers
  • Pls help will give brainlest​
    15·2 answers
  • Why is yo utu be down?<br> (You restrict talking about yo utu be, really)
    11·2 answers
  • Ranboo back story? (not homework i just wanna find some ppl who are interested in the same things) ft. the reddie meme
    9·2 answers
  • A collection of wiress connecting the CPU with main memory that is used to identify particular location is called
    13·1 answer
  • List 5 differences between monitors and printers​
    14·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!