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
lapo4ka [179]
3 years ago
15

Write an if/else statement that compares the value of the variables soldYesterday and soldToday, and based upon that comparison

assigns salesTrend the value -1 or 1. -1 represents the case where soldYesterday is greater than soldToday; 1 represents the case where soldYesterday is not greater than soldToday.
Computers and Technology
1 answer:
jenyasd209 [6]3 years ago
7 0

Answer:

if(soldYesterday > soldToday){

salesTrend = -1;

} else if(soldToday > soldYesterday){

salesTrend = 1;

}

Explanation:

The if/else statement is more explicit. The first if condition check if soldYesterday is greater than soldToday, if true, then -1 is assigned to salesTrend.

Else if soldToday is greater than soldYesterday, if true, then 1 is assigned to salesTrend.

You might be interested in
6. At age 17, what was Minhaj's definition of the American Dream?
marta [7]
“To me being American means having the opportunity to reach for our goals. It’s accepting where we come from while embracing our dreams and where we’re headed. It’s what makes America great.”
3 0
3 years ago
How would you define data science ?
Lady bird [3.3K]

Answer:

My take on Data  Science is extracting any valuable insight or information from the data given to us or data that we have by using certain programming languages,data manipulation techniques,algorithms.Also representing the result in different form possible like graphs,plots,scatter plots etc.

data science is growing very rapidly and becoming popular day by day.

5 0
3 years ago
The component that allows you to make a paper-based copy of a body of text is the _____.
ANTONII [103]
The correct answer is: Scanner

The scanner is a piece of technology which unlike the printer is an input device which basically scans the top-view of any flat surface (usually paper but is definitely not limited to it) introduced in its effective range using light. The data scanned is then transfered to the Central Processing Unit for futher processing. The processed image can then be outputted and seen on the monitor's display. Once available for printing, the Central Processing Unit will just send the processed image into the printer ad voila, your scanned image is now printed in a piece of paper!

Today, scanners come with printers as a bundle. It is a perfect combination since the printer will just print the image anyway.
5 0
3 years ago
When a user receives an email warning about the dire consequences of possible virus attacks on their pc or tablet, it is often a
Sliva [168]
Sometime it's a scam an sometimes it's true
7 0
3 years ago
The automotive system that connects the engine and the transmission to the wheels is called the
insens350 [35]
I believe the driveshaft 

8 0
3 years ago
Other questions:
  • What is the other name of the horizontal column graph?
    6·2 answers
  • Which program can damage your computer
    13·2 answers
  • The file extensions .webm, .m4v, and .ogv are used for:
    15·1 answer
  • What could be one rule to help your friend to blog safely
    6·2 answers
  • An inventory management system that goes beyond just managing inventory to act as a complete distribution system (including inve
    10·1 answer
  • BEING TIMED HELP ASAP
    12·2 answers
  • Seeing an error message on the screen after you click on a link or icon may indicate that your PC doesn't have the correct _____
    15·1 answer
  • 1. What makes discrimination different from harassment? (Don't give me definitions.)
    5·1 answer
  • The illustration shows different types of text language.
    5·2 answers
  • Does anyone have any tips on how to begin a 10 page Capstone project paper? I've got to write a write a research paper on the ty
    14·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!