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

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 15:10
David is in week 3 of his current ashford course and has a paper due by monday night at midnight. he has finished everything but the concluding paragraph. as he boots up his computer to work on it, he sees a flash across the screen and then the screen goes black. he begins to panic as he tries desperately to turn the laptop back on. david should have saved his work on what kind of portable device?
Answers: 2
question
Computers and Technology, 23.06.2019 10:00
Now, open this passage to read about fafsa requirements. describe the information you will need to provide in order to complete a fafsa. list at least three of the required documents you must include.
Answers: 3
question
Computers and Technology, 24.06.2019 00:20
Describe a data structures that supports the stack push and pop operations and a third operation findmin, which returns the smallest element in the data structure, all in o(1) worst-case time.
Answers: 2
question
Computers and Technology, 24.06.2019 04:30
Which of the following terms refers to a collection of different types of software that share the goal of infiltrating a computer and making it do something? a- malware b- virus c- spyware d- trojan horse
Answers: 2
You know the right answer?
Write if statements to do the following: – If character variable taxCode is ’T’, increase price by...
Questions
question
History, 18.09.2019 19:10
question
Mathematics, 18.09.2019 19:10
Questions on the website: 13722359