Yahoo Answers is shutting down on May 4th, 2021 (Eastern Time) and beginning April 20th, 2021 (Eastern Time) the Yahoo Answers website will be in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.
Jacob
Any help with this program?
I'm using Dr.Java to make a program that tells the user how much they pay for their internet service. It was going well enough but I found a syntax error that I can't find any way to fix. It shows exactly where the error is but as I've only been taking programming for a few months I have no idea how to fix it. So really anything that can get rid of errors would be appreciated.
I'm leaving the program below because I can't leave it as a file and I commented on the area where the problem is so you can hopefully just look at it and say what's wrong. Thanks in advance for the help.
import java.util.Scanner;
public class TestSpace{
public static void main (String[]args){
Scanner Service = new Scanner (System.in);
//Asks questions
System.out.println("Which package do you have? A ,B, or C");
String PackageChoice = Service.nextLine();
System.out.println("How many hours was internet used");
int Hours = Service.nextInt();
//lists payments
double Apay = 9.95;
double Bpay = 13.95;
double Cpay = 19.95;
if (PackageChoice.equals ("A")){
if (Hours <=10)
System.out.println("You pay $"+Apay+" this month");
if (Hours >=11)
//error below
double totalA= ((Hours-10)*1.95) + Apay
System.out.println("You pay $"+toatlA+" this month");
}
}
}
2 AnswersProgramming & Design8 years agoInjustice, Defiance, or Infinite?
Okay so very soon three big video game are going to be released. Injustice: Gods Among Us, Defiance, and Bioshock Infinite. I really want all three but my wallet says that's not going to happen. So I need to decide which one to get.
Injustice is D.C. characters fighting with the Mortal Kombat style. I want this one because I love both D.C. and Mortal Kombat so it obviously it looks good. All of the videos that i've seen for it so far have made it look good and the overall combat look amazing.
Defiance is a third person shooter that is directly connected to the new Syfy show of the same name. I want this one because it's interconnected with the show and will continually change with the show, so I would like to be there from the beginning. But I also don't want it because i'm the guy who plays a game a few weeks then moves on, so I probably wouldn't play it throughout the whole show.
Bioshock Infinite is the next chapter in the highly acclaimed Bioshock series. The new powers, the story, the location, and the enemies all make it look like it will be absolutely amazing. I've only played a few hours of the original Bioshock but I remember it being fantastic so i'm assuming that Infinite will be just as good.
Which one do you think I should get? Any comments that help me decide are appreciated.
3 AnswersVideo & Online Games8 years agoHow to make a tall tower made of 2 pieces paper?
I need to build a tall tower using just 2 pieces of paper, 18" of masking tape, and scissors for school . Any schematics, suggestions, or tips would be greatly appreciated.
3 AnswersEngineering10 years ago