How do I get one If to change two variables (Java)?
-
My program is an assignment for helping choose phone plans. I want the lines below to do this: Output: How many minutes does this plan offer? If the input is zero, then the phone plan has unlimited minutes. So the variable planAminutes = 0 but I also want planAchargeMinutes, the variable dealing with overcharges for going over the number of minutes (but isn't needed since it's unlimited) to also = 0. The else function will input the number of minutes the plan offers. what I've got is: The output if (keyboard.nextInt() == 0) planAminutes = 0; else planAminutes=keyboard.nextInt(); How do I get the if statement to also alter a second variable?
-
Answer:
sorry i cant help but it seems like your doing stuff more advanced than i am, would you be able to help me out with a java program?
Craig H at Yahoo! Answers Visit the source
Related Q & A:
- What are Yahoo! Groups and how do I get to one?Best solution by groups.yahoo.com
- How do I get rid of one of my Yahoo email addresses?Best solution by Yahoo! Answers
- How can I get my regular avatar of a real picture back as my avatar instead of the one now?Best solution by Yahoo! Answers
- How do i get or change my email alert?Best solution by Yahoo! Answers
- How do I get off this stupid new yahoo home page and back to my old one?Best solution by Yahoo! Answers
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.