I keep gettin this error message when i try to compile can't fix

MY CODE
import java.text.DecimalFormat;
public class MotelBase{
private int nite;
private int numadult;
private int numchild;
final double ADULT_RATE = 25.0;
final double CHILD_RATE = 8.0;
public MotelBase (int inNite, int inNumAdult, int inNumChild){
     nite = inNite;
     numadult = inNumAdult;
     numchild = inNumChild;}
public int getNumAdult(){return numadult;}
public int getNumChild(){return numchild;}
public int getNite(){return nite;}
public double getAchg(){return numadult * nite * ADULT_RATE;}
public double getCchg(){return numchild * nite * CHILD_RATE;}
public double getBase;{return (getAchg + getCchg);}
public double getTax;{return (getBase) * .10;}
public double getTotal;{return (getTax) + (getBase);}
public void setNite(int inNite){nite = inNite;}
public void setNumAdult(int inNumAdult){numadult = inNumAdult;}
public void setNumChild(int inNumChild){numchild = inNumChild;}
public String toString(){return "Number of Adults: " + this.numadult + "\n" +
                                "Number of Children: " + this.numchild + "\n" +
                                "Number of Nights: " + this.nite + "\n" +
                                "Base rate: " + this.getBase + "\n" ;}}
**Here are the error messages when i compile**
javac -d . -g -classpath . MotelBase.java
MotelBase.java:17: return outside method
public double getBase;{return (getAchg + getCchg);}
^
MotelBase.java:18: return outside method
public double getTax;{return (getBase) * .10;}
^
MotelBase.java:19: return outside method
public double getTotal;{return (getTax) + (getBase);}
^
3 errors
Can anyone help me

so i removes the semi's and added ()'s
public double getBase(){return (getAchg) + (getCchg);}
public double getTax(){return (getBase) * .10;}
public double getTotal(){return (getTax) + (getBase);}
and this happened
javac -d . -g -classpath . MotelBase.java
MotelBase.java:17: cannot find symbol
symbol : variable getAchg
location: class MotelBase
public double getBase(){return (getAchg) + (getCchg);}
^
MotelBase.java:17: illegal start of type
public double getBase(){return (getAchg) + (getCchg);}
^
MotelBase.java:17: cannot find symbol
symbol : variable getCchg
location: class MotelBase
public double getBase(){return (getAchg) + (getCchg);}
^
MotelBase.java:17: illegal start of type
public double getBase(){return (getAchg) + (getCchg);}
^
MotelBase.java:17: incompatible types
found : java.lang.String
required: double
public double getBase(){return (getAchg) + (getCchg);}
^
MotelBase.java:18: cannot find symbol
symbol : variable getBase
location: class MotelBase
public double getTax(){return (getBase) * .10;}
^
MotelBase.java:18: illegal start of type
public double getTax(){return (getBase) * .10;}
^
MotelBase.java:19: cannot find symbol
symbol : variable getTax
location: class MotelBase
public double getTotal(){return (getTax) + (getBase);}
^
MotelBase.java:19: illegal start of type
public double getTotal(){return (getTax) + (getBase);}
^
MotelBase.java:19: cannot find symbol
symbol : variable getBase
location: class MotelBase
public double getTotal(){return (getTax) + (getBase);}
^
MotelBase.java:19: illegal start of type
public double getTotal(){return (getTax) + (getBase);}
^
MotelBase.java:19: incompatible types
found : java.lang.String
required: double
public double getTotal(){return (getTax) + (getBase);}
^
MotelBase.java:26: cannot find symbol
symbol : variable getBase
location: class MotelBase
"Base rate: " + this.getBase + "\n" ;}}
^
13 errors
it seem like everytime i fix something there is a virtual landrush of errors, i appreciate all of your help thank you for taking the time to answer my questions

Similar Messages

  • I keep getting this error message when I try to download Photoshop Elements -413  Header Length too Large

    i keep getting this error message when I try to download Photoshop Elements -413  Header Length too Large
    Any suggestions gratefully received

    clear your adobe.com cookies or use a different browser.

  • I keep getting this error message when i try to install the latest version of itunes, the program can't start because MSVCR80.dll is missing from your computer. try reinstalling the program to fix this problem??

    I am having trouble reinstalling my Itunes on my desktop which uses Windows 7 and I can download it but once it's complete i keep getting this error message...The program can't start because MSVCR80.dll is missing from your computer. Try reinstalling the program to fix this problem. Please help me.

    Go to Control Panel > Add or Remove Programs (Win XP) or Programs and Features (later)
    Remove all of these items in the following order:
    iTunes
    Apple Software Update
    Apple Mobile Device Support (if this won't uninstall move on to the next item)
    Bonjour
    Apple Application Support
    Reboot, download iTunes, then reinstall, either using an account with administrative rights, or right-clicking the downloaded installer and selecting Run as Administrator.
    The uninstall and reinstall process will preserve your iTunes library and settings, but ideally you would back up the library and your other important personal documents and data on a regular basis. See this user tip for a suggested technique.
    Please note:
    Some users may need to follow all the steps in whichever of the following support documents applies to their system. These include some additional manual file and folder deletions not mentioned above.
    HT1925: Removing and Reinstalling iTunes for Windows XP
    HT1923: Removing and reinstalling iTunes for Windows Vista, Windows 7, or Windows 8
    tt2

  • I keep getting this error message when I try to open a project?

    Projects created with Adobe Premiere Pro and Adobe Premiere Elements are not compatibe. Please use the appropriate application to open this project.
    I have tryed to open old projects/start new and just keep getting this message.
    Thanks in advance for the help.

    Leha23
    Thanks for the follow up. Let us go through the usual drill for users of Premiere Elements 8 (not too old from my point of view).
    1. Are you working from the 8.0.1 Update of the program? That is very important for everyday performance of the version.
    2. Do you have the automatic features of Background Rendering and AutoAnalyzer turned off. Very important since they are major grabbers of computer resources. Both are in preferences, Background Rendering in the Premiere Elements workspace Edit Menu/Preferences/General and AutoAnalyzer in the Elements Organizer workspace Edit Menu/Preferences/AutoAnalzyer options.
    3. Let us try flushing the preferences...the path for Windows 8 64 bit would be
    Local Disk C
    Users
    Owner
    AppData
    Roaming
    Adobe
    Premiere Elements
    8.0
    and in the 8.0 Folder is the Adobe Premiere Elements Prefs file that you delete. If that does not do the job, the delete the whole 8.0 Folder in which the Adobe Premiere Elements Prefs exists.
    Make sure to be working from Folder Options Show Hidden Files, Folders, and Drives active so that you can see the complete path.
    I did not see anything in Hunt's link that cited your error message specifically. It appeared to be an overall troubleshooting article on damaged projects. I did not go down that path since you said that you are having the error message problem with new as well as old projects.
    About 3 years ago, I worked with another Premiere Elements 8 user with this same error message. In that case, it spontaneous disappeared. When you get this error message, does it present with an OK or Continue button? This problem has been reported before here and with Premiere Elements 8.0/8.0.1. In each case, the core of the problem was left undefined.
    Looking forward to your follow up.
    Thanks.
    ATR

  • The iPad "my iPad name" could not be synced because the iPad could not be found on the network.  Why am I keep receiving this error message when i try to wifi synce my iPad?

    How can I fix this problem?  The iPad appears under devices in iTunes but when i try to synce it, thats the error message I receive.

    Hello Gentlemen,
    I too have the same problem, and I see that nobody has found a working fix yet. How dissapointing. I would have thought that Apple would have tried to fix this by now. Who knows how many others are in the same boat?
    I am unable to sync my iPad at all. This means that I can't make a backup and so can't clean and restore it. I can't add any music. I can't get my photos off the iPad either. And so on! My brand new iPad is incapable of doing anything usefull! Don't fret Apple, I WILL tell all my friends what my opinion of your devices are.
    In my opinion this is a CRITICAL FAILURE FROM APPLE!
    I believe that it's undeniable that this is a stupid uniformative error message that leads me nowhere.  Of course the connection went away. BUT WHY? HOW AM I SUPPOSED TO RESOLVE THE PROBLEM IF YOUR ERROR MESSAGE  DOESN'T GIVE ME ANY USEFULL INFORMATION????
    AND WHY CAN'T I CAUSE IT TO SKIP OVER THE BACKUP STEP SO AT LEAST THE DEVICE HAS SOME FUNCTIONALITY?
    There are no published fixes that work.  The only thing close, was a recommendation to reset the iPad and try again. This didn't do anything but waste more of my time.
    Hopefully, my Rant will cause someone to take a stab at coming up with a resolution. I JUST NEED TO KNOW HOW TO GET MY IPAD WORKING AGAIN.
    Is that too much to ask?
    Regards,
    Steve

  • I keep receiving an error message when i try to sync my phone of : 1450 What does this mean?

    I keep receiving an error message when I try to Sync my I phone 4.  It says Can't Sync 1450.  What does this mean?  I've had this phone for over a year with no problems.

    Yep. Tried that. And just did it again.
    Still no joy.

  • I keep getting an error message when I try to sync my ipad or iphone to my iMac:  "The iPad (or iPhone) cannot be synced.  An unknown error occurred (-50)."  What is this about?  Thanks

    I keep getting an error message when I try to sync my iPad or iPhone to my iMac, as follows:  The iPad "_________" cannot be synced.  An unknonw error occurred (-50).  Does anyone know what this is about - thanks.

    Error -50 is a very unhelpful generic communications error with a number of possible causes.  Something between the drive to which you are downloading and the drive from which it is all coming is not working correctly, which probably leaves several hundred options.

  • I keep getting this error message when I (right-click) on a photo file on my desktop to burn to a CD. I don't understand this code...does anyone?  Thanks  Ariel**:The disc can't be burned because an unexpected error occurred (error code 0x80020000).

    I keep getting this error message when I (right-click) on a photo file on my desktop to burn to a CD. I don't understand this code...does anyone?  Thanks  Ariel**:    The disc can’t be burned because an unexpected error occurred (error code 0x80020000).

    I tried every obvious solution to this problem with different types of disc (-R; +R; -RW and +RW) and the problem persisted.  Then I read about removing a hyphen in picture filenames.  I renamed all the images and bingo there were no further problems.  Apple should have solved this by now.  This error code has been reported for several years and my MacBook Pro is quite new.  Anyway, I hope this helps.  It does work.
    Piggywiggle

  • I'm gettin an error message when I try to play a movie a rented using Apple TV 2nd generation. How do I solve this?

    i'm gettin an error message when I try to play a movie a rented using Apple TV 2nd generation. How do I solve this?

    I don't believe I've seen a solution to that error code. There's a new version of iTunes out, have you installed it yet, it might be worth trying. You might also try restarting your Apple TV and router.

  • I keep receiving an error message when I try to send an adobe document through Outlook email.

    I keep receiving an error message when I try to send an adobe document through Outlook email.
    The message is : Either there is not default mail client or the current mail client cannot fulfill the message request. Please run Microsoft Outlook and set it as the default mail client.
    I have checked everywhere on my system and changed Microsoft Outlook as the default mail program but nothing is helping. Does anyone have any ideas?

    I am having the same issue, just replied to a different post on the issue.  I am running Acrobat X Pro with Win 7 Pro 64-bit.  This is a new PC, but my last PC was a 32-bit OS and I didn't have this issue.  I was suspecting that it is due to the 64-bit OS. 
    Reading this post though, I am starting to wonder if there isn't something else going on.  When I go to Edit>Preferences, I don't have anything related to email under Categories, or even within any of the categories listed.  I am I missing a plug in or something?  Or is this a component of a previous version of Acrobat?
    I tried to attach a screenshot of the error message but getting a new error while trying to attach!  File is only 25kb!  Will have to live without i guess.

  • I have a Macbook Pro. I just purchased Acrobat Pro DC and keep getting an error message when I try to download, saying I need to contact support.

    I have a Macbook Pro. I just purchased Acrobat Pro DC and keep getting an error message when I try to download, saying I need to contact support. I've eliminated previous versions of the application because they were US-based versions and I'm now living in Australia. I checked Flash and it seems to be installed correctly. what am I doing wrong?

    Hi Laura ,
    Could you please elaborate about the issue and also about the error message?
    What does it say except contacting the support?
    Is it something to do with Licensing and Activation of Acrobat DC?
    Also please update us from where are you trying to download Acrobat DC?
    I would recommend you to follow these links download Acrobat DC and see if you still face any challenges .
    If you want to opt for perpetual ,follow this link .
    Download Acrobat products | Standard, Pro | DC, XI, X
    And if you wish to subscribe for Acrobat DC .Kindly refer this link .
    Download Acrobat DC (Continuous) | Enterprise or VIP
    Regards
    Sukrit Dhingra

  • I keep getting an error message when i try to send emails.

    I just got the palm treo 650 on alltel.  didn't realize it was going to be so involved. lol  I got email set up but keep getting an error message when i try to send.  the message is 530 5.7.0 must issue a STARTTLS command first.  What does that mean and how do i fix it? 
    Thanks in advance.
    Post relates to: Treo 650 (Alltel)

    Our CEO at our hospital has the exact same problem with this phone, we have been workign with alltel on the problem for quite some time now, and cant seem to find a solution. His can receive emails with no problems but gets an error code 530 when tryng to send an email. But he only gets the error when he is outside of the alltel network. If hes in our hometown then everything works great. Needless to say hes been getting quite irritated with the problem and needs it fixed ASAP. If anyone every figures out a soluting to this problem please let me know.
    Thanks
    Post relates to: Treo 650 (Alltel)

  • HT4009 I keep getting an error message when I try to buy in app purchases

    I keep getting an error message when I try to buy in app purchases

    To Contact iTunes Customer Service and request assistance
    Use this Link  >  Apple  Support  iTunes Store  Contact
    Note:
    Some In-App purchases require a Credit Card.

  • I keep getting an error message when I try to log into to ExportPDF through my Adobe Reader. "Network error occurred while attempting to sign in". Can anyone help, please?

    I keep getting an error message when I try to log into to ExportPDF through my Adobe Reader. "Network error occurred while attempting to sign in". Can anyone help, please?

    Hi Simon,
    I'm sorry to hear that you're having trouble logging in to ExportPDF via Reader. I've checked your account, and all is well there.
    For starters, please make sure that you have the most current version of Reader installed by choosing Help > Check for Updates.
    If you're still having trouble logging in via Reader, please try logging in to the web interface at https://cloud.acrobat.com.
    Please let us know how it goes.
    Best,
    Sara

  • I keep getting an error message when I try to sync my new iPhone5s to iTunes. It says my computer is not authorised. When I authorise it and try and sync again, the same error message appears. help?

    I keep getting an error message when I try to sync my new iPhone 5s to iTuines.
    It says my computer is not authorised.
    When I authorise it successfully, and try and sync again, the same error message appears.
    Help?

    Hello Chad176
    If you are constantly Authorizing your Apple ID, the article below will assist with getting that resolved for you.
    iTunes repeatedly prompts to authorize computer to play iTunes Store purchases
    http://support.apple.com/kb/TS1389
    Thanks for using Apple Support Communities.
    Regards,
    -Norm G.

Maybe you are looking for