subject
Computers and Technology, 15.08.2021 14:40 401666

Write if statements to do the following: – If character variable taxCode is ’T’, increase price by adding the taxRate percentage of price to it.
– If integer variable opCode has the value 1, read in double values for X and Y and calculate and print
their sum.
– If integer variable currentNumber is odd, change its value so that it is now 3 times currentNumber
plus 1, otherwise change its value so that it is now half of currentNumber (rounded down when
currentNumber is odd).
– Assign true to the boolean variable leapYear if the integer variable year is a leap year. (A leap year is
a multiple of 4, and if it is a multiple of 100, it must also be a multiple of 400.)
– Assign a value to double variable cost depending on the value of integer variable distance as follows:
Distance Cost

0 through 100 5.00
More than 100 but not more than 500 8.00
More than 500 but less than 1,000 10.00
1,000 or more 12.00

ansver
Answers: 3

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 14:30, chaparro0512
Create a pseudocode design to prompt a student for their student id and the titles of the three classes they want to add. the solution should display the student’s id and a total bill. • bill a student using the following rules: o students can only add up to 3 classes at a time.
Answers: 3
image
Computers and Technology, 23.06.2019 04:31, tbt81
Type the correct answer in the box. spell all words correctly. the managing director of a company sends a christmas greeting to all his employees through the company email. which type of network does he use? he uses an
Answers: 1
image
Computers and Technology, 24.06.2019 01:00, kayranicole1
What shows the web address of the page that is currently displayed in the workspace? status window toolbar location bar internet box
Answers: 1
image
Computers and Technology, 24.06.2019 14:00, ratpizza
Which describes careers that have similar education requirements but different qualifications? product safety engineers and materials engineers industrial safety engineers and industrial health engineers quality control systems managers and inspectors industrial safety and health engineers and hand packers
Answers: 3
You know the right answer?
Write if statements to do the following: – If character variable taxCode is ’T’, increase price by...

Questions in other subjects: