Answered step by step
Verified Expert Solution
Question
1 Approved Answer
1. Assume you have a variable named itemPrice. Design question: what would be the best data type for it and why? Write one line of
1. Assume you have a variable named itemPrice. Design question: what would be the best data type for it and why? Write one line of code that would print your item's price to two decimal places of precision.
2. In C++, if we wanted to see if two strings were the same, we'd use ==. When we use == between Strings in Java, what happens? What should we do instead?
3. If a = 1, b = -4, and c = 9, what does the following expression evaluate to? Show your work at every step, don't just put T or F as the answer to this.
a > b || !(c == 9) && (a+b == 3)
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started