Describe if statement with example


Problem:

Question- 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 .

Write the code step by step and explain it.

Request for Solution File

Ask an Expert for Answer!!
Computer Engineering: Describe if statement with example
Reference No:- TGS0893111

Expected delivery within 24 Hours