Can anyone write script for this

You need to create a class called ?Account? that represents a bank account. The data describing each account consists of the customer?s account number, name and the current balance. Method shoud be provided to deposit an amount of money and to withdraw an amount of money and to get the current balance.
Class Account may like the following
class Account{
     protected int accountNumber;
     protected String firstName;
protected String lastName;
protected float balance;
protected String message;
protected String accountType;
     //default constructor
public Account(){*add your definition here*/}
//constructor
public Account(String firstName,String lastName,
float balance}
{*add your definition here*/}
public void deposit(float amount)
{*add your definition here*/}
public void withdraw(float amount)
{*add your definition here*/}
public void balance()
{*add your definition here*/}
public void display(Graphics g, int x, int y)
{/*add your code here:print out accout type*/
/*print out name,accountNumber and ?message?*/}
You also need to create two classes: Checking and Saving both inherited from classs Account. Provide both classes with their own contructors. A checking can go overdrawn (the balance can be less than zero). A saving cann?t go overdrawn. Add an additional data member interestRate to the class Saving. Add an additional data member called limit to the class Checking. It represents overdraft limit. For example, if the overdraft limit is 500, any request of withdrawing that causes the balance of the checking account under ?500$ would be denied. You need to override methods withdraw in both classes.
You also need to create a user interface class called UseAccount
?     The beginning of this class could be
private Account account;
private Checking checking;
private Saving saving;
private Choice accountChoice;
private String choice="Checking";
?     Create objects ?checking? and ?saving? in your ?createGUI? method and assign object ?account? to the default one.
?     Add a textField called amountField to allow people to enter the amount they want to deposit or withdraw. Also add a Label with it
?     Add three buttons: deposit, withdraw and balance
?     Add a Choice box that has two options: Checking and Saving. Set default choice as Checking or Saving as you like
?     When you press a button, action happens on the approprite account
?     Whenever you make a deposit or withdraw, print out the account number, account type and what you have done in this account.
?     Use the polymorphism, you actionPerformed method could be
if(event.getSource()==withdraw){
     Float amount=Float.valueOf(amountField.getText());
     account.withdraw(amount);}
You itemStateChanged method could be
if(e.getSource()==accountChoice){
          String aChoice=e.getItem().toString();
          if(aChoice.equals(?Checking?))
               account=checking;
?     When a transaction is made or denied, you should display an appropriate message. For example, the message could be:
Account Type: Checking
Name: George Bush
Account Number: 1010
Deposit amount: $120.
Transaction success! ?.
Or
Account Type: Checking
Name: George Bush
Account Number: 1010
Withdraw amount: $1000.
Request denied! Exceed the overdraft limit!
this is my assignmnets .. as i dont get what my teachers teache sin class i dont know how to wring programs in java ...littl ehelp frm u can help meh to understand the java and of course complet my assignmnet

whast is wrong with u guys if u guys can come with
the solution .. ..then plz .. dont write here just to
increase . ur post ....Nobody is posting here to increase their post count. Typically, when some chucklehead comes along and says, "Hello. I am lazy and a pathetic waste of a student. Please do my homework for me, because I want a free ride..." - the thread get hijacked and turned into some nonsensical, totally unrelated mess. NO ONE IS GOING TO DO YOUR DAMN HOMEWORK FOR YOU, SO GROW A F*CKING BRAIN, GET OFF YOUR LAZY A SS AND DO IT YOURSELF.
Oh ... and have a nice day :-)

Similar Messages

  • When i update my IOS7 i lost my all pic from my IPAD2 how to get back those pic? and i don,t think so i did kept back up before i did that. can anyone help me for this issue?

    When i update my IOS7 i lost my all pic from my IPAD2 can anyone suggest how to get back those pic? and i don,t think so i did kept back up before i update ios7. can anyone help me for this issue?

    The photo's in your camera roll would be in a backup, if you have one (iCloud or iTunes).  If you did not keep a backup somewhere, they are gone.  Sorry, but that is the way of any data - if you don't have a backup of it somewhere, there is nothing to restore it from.
    All other photo's should be on your computer somewhere anyway - whereever you had them to sync to the device originally.

  • I unable to see my network messages after upgrading to ios6 on my iphone4,can anyone help me for this issue?

    I unable to see my network messages after upgrading to ios6 on my iphone4,can anyone help me for this issue?

    Try to perform SMC and PRAM resets:
    http://support.apple.com/kb/HT3964
    http://support.apple.com/kb/ht1379
    Then try a safe boot:
    http://support.apple.com/kb/HT1564
    Ciao.

  • How Can I write Script for Indesign set left indent

    I really need two scripts for indesign set left indent:
    1. If the left indent is: 8, 16, 24, 32, 40, 48, 56mm... set the first -8mm; if the left indent is 0, set the left indent 8mm, first -8mm.
    2. Whatever the first indent is, set the first 8mm.
    Can someone help me?

    Hi, Trevor
    I use change by list as below:
    grep {leftIndent:48mm} {leftIndent:56mm}
    grep {leftIndent:40mm} {leftIndent:48mm}
    grep {leftIndent:32mm} {leftIndent:40mm}
    grep {leftIndent:24mm} {leftIndent:32mm}
    grep {leftIndent:16mm} {leftIndent:24mm}
    grep {leftIndent:8mm} {leftIndent:16mm}
    grep {firstLineIndent:8mm, leftIndent:48mm} {firstLineIndent:8mm, leftIndent:56mm}
    grep {firstLineIndent:8mm, leftIndent:32mm} {firstLineIndent:8mm, leftIndent:48mm}
    grep {firstLineIndent:8mm, leftIndent:24mm} {firstLineIndent:8mm, leftIndent:32mm}
    grep {firstLineIndent:8mm, leftIndent:16mm} {firstLineIndent:8mm, leftIndent:24mm}
    grep {firstLineIndent:8mm, leftIndent:8mm} {firstLineIndent:8mm, leftIndent:16mm}
    grep {firstLineIndent:-8mm, leftIndent:48mm} {firstLineIndent:-8mm, leftIndent:56mm}
    grep {firstLineIndent:-8mm, leftIndent:32mm} {firstLineIndent:-8mm, leftIndent:48mm}
    grep {firstLineIndent:-8mm, leftIndent:24mm} {firstLineIndent:-8mm, leftIndent:32mm}
    grep {firstLineIndent:-8mm, leftIndent:16mm} {firstLineIndent:-8mm, leftIndent:24mm}
    grep {firstLineIndent:-8mm, leftIndent:8mm} {firstLineIndent:-8mm, leftIndent:16mm}
    but not that perfect,
    I want to useing jave "if{}" or "for{}" to write this script, but I don't kown the syntext.

  • Hi there, can anyone please help? Download itunes and it says The Itunes library .itl file is locked, or on a locked disk or you do not have write permission for this file.

    Hi there, can anyone please help? Download itunes and it says The Itunes library .itl file is locked, or on a locked disk or you do not have write permission for this file.

    Holding down the shift key while iTunes is opening. That will bring up the 'choose iTunes library' dialog. Select 'Choose LIbrary' from the choices and navigate to your music folder and iTunes music folder.
    Or refer to this article:
    iTunes for Windows XP: "Disk is locked" or "iTunes folder cannot be found" when installing or opening iTunes
    http://support.apple.com/kb/HT1866

  • Can anyone write a actionscript for flash project

    Hi All,
    Can anyone write a Actionscript for my project.
    I want to develop my project with the flash.
    My project scenario is, I have total no of 60 (.swf) flash
    movies and are about to take 4 to 5 minutes each, my aim is to
    display 20 .swf files randomly at a time on the screen.
    i.e., if we click on a button for the first time, it should
    display a 20 flash movies on the screen and when we click for the
    second time it should display other set of 20 flash movies it may
    or may not repeat the previous ones. It means every person should
    be displayed with a different set of flash movies, no two persons
    can get the same set of movies. The movies should be randomly
    selected.
    Could you please direct me to meet my scenario, could you
    please write a script for my flash.
    Thank you for your precious time.

    Ndippy,
    Folks on here are pretty good about helping out others who
    are trying to learn actionscript, or have trouble with
    understanding concepts. They are less likely to volunteer to do an
    entire project for you. I'd suggest trying to do it yourself, and
    asking specific questions about the process. Both of your posts are
    way to general to allow anyone to give advice that would be
    worthwhile. You have said that you have 60 .swfs in your first
    post. However, in your second, you said they were 60 quicktime
    files. There are very different processes for each option there.
    Are you planning to display 20 at once, or let people scroll
    through them? What size are your clips and what size are you
    developing for?
    Start small, like just trying to load one movie clip
    randomly, and then work your way up. Experiment with changing the
    positions, sizes, etc. When you run into trouble, ask a specific
    question about what you are trying to do, and people will be happy
    to help.

  • I am trying to open iTunes on my mac. But a box pops up saying "The folder iTunes is on a locked disk or you do not have write permissions for this folder". Anyone know what that means? I've had my computer 2 years and its never had a problem opening it

    I am trying to open iTunes on my mac. But a box pops up saying "The folder iTunes is on a locked disk or you do not have write permissions for this folder". Anyone know what that means? I've had my computer 2 years and its never had a problem opening it

    I've already right-clicked on the application, clicked "get info", and changed it so all people listed in the "Sharing & Permissions" section have the "read & write" privilage.
    The error message is referring to your iTunes library, not your iTunes application.
    You need to check and fix the permissions of the iTunes folder in your iTunes library. This is by default located in your "Music" folder.
    Select the folder Music > iTunes  in the Finder, right click on it or Ctrl Click and click "Get Info". At the bottom of the contextual window thatwill  pop up, disclose the Sharing and Permissions brick, change your status from Read only to Read & Write. You may need to click the padlock icon to make changes.

  • My imac will not load after I enter my password. The only thing I get is the arrow from my mouse on top of a blank white screen.  Can anyone tell me what this is?  I've restarted and turned off several times.  I left it on in this state for 8 hours and

    My imac will not load after I enter my password. The only thing I get is the arrow from my mouse on top of a blank white screen.  Can anyone tell me what this is?  I've restarted and turned off several times.  I left it on in this state for 8 hours hoping it would reload and work.  No luck.

    Hello KCC4ME,
    You may try booting your Mac in Safe Boot, as it can resolve many issues that may prevent a successful login.
    OS X: What is Safe Boot, Safe Mode?
    http://support.apple.com/kb/HT1564
    If a Safe Boot allows you to successfully log in, you may have issues with one or more login itmes (while the following article is labelled as a Mavericks article, it is viable for earlier versions of the Mac OS, as well).
    OS X Mavericks: If you think you have incompatible login items
    http://support.apple.com/kb/PH14201
    Cheers,
    Allen

  • I need to reinstall my operating system for 10.5 after seeing a file folder and question mark flashing on my start up screen. Can anyone help me with this?

    I need to reinstall my operating system for 10.5 after seeing a file folder and question mark flashing on my start up screen. Can anyone help me with this?

    Hello,
    That means it can find the Hard Drive, or can't find the things needed for booting.
    See if DU even sees it.
    "Try Disk Utility
    1. Insert the Mac OS X Install disc, then restart the computer while holding the C key.
    2. When your computer finishes starting up from the disc, choose Disk Utility from the Installer menu at top of the screen. (In Mac OS X 10.4 or later, you must select your language first.)
    *Important: Do not click Continue in the first screen of the Installer. If you do, you must restart from the disc again to access Disk Utility.*
    3. Click the First Aid tab.
    4. Select your Mac OS X volume.
    5. Click Repair Disk, (not Repair Permissions). Disk Utility checks and repairs the disk."
    http://docs.info.apple.com/article.html?artnum=106214
    Then try a Safe Boot, (holding Shift key down at bootup), run Disk Utility in Applications>Utilities, then highlight your drive, click on Repair Permissions, reboot when it completes.
    (Safe boot may stay on the gray radian for a long time, let it go, it's trying to repair the Hard Drive.)

  • I've just opened iTunes on my Mac with an error "The iTunes Library.itl file is locked, on a locked disk, or you do not have write permission for this file.". I created a shirred library so that all users on my Mac can access the same library. Help?

    I have just opened ITunes on my Mac and the following error occurred "The iTunes Library.itl file is locked, on a locked disk, or you do not have write permission for this file.". When I setup my Mac I created a shared user area to contain my ITunes library so that I could share it with another user logged onto my Mac. However the error above gives me the impression that the library file is locked... I've checked and it does not seem to be locked under the "get info" fie information. Has anyone come across this before and found a solution?

    You also need to make sure you have both read and write permission for the file, or for the whole iTunes folder for that matter.  That's also done in Get Info for the file or folder concerned.
    Read the part about changing permissions on the iTunes folder in: https://discussions.apple.com/message/11583914

  • Can anyone help or answer this question for me. Is there a way to have a private album for pictures sent to my phone? Don't exactly want kids ( niece and nephew ) to play on my phone and see private pictures of my girlfriend

    Can anyone help or answer this question for me. Is there a way to have a private album for pictures sent to my phone? Don't exactly want kids ( niece and nephew ) to play on my phone and see private pictures of my girlfriend

    What about this?
    https://itunes.apple.com/ru/app/best-secret-folder/id488030828?l=en&mt=8

  • Just finished using iTunes, closed out and then tried to get back in.  Got this message "he iTunes library .itl file is locked, on a locked disk, or you do not have write permission for this file."  How can I get back into iTunes ?

    I just finished using iTunes, closed out and then tried to get ack in.  Got this message "The iTunes library .9tl file is locked, on a locked disk, or you do not have write permission for this file."   How can I get back ino iTunes ?

    I actually figured it out...I had to go to the iTunes Library Extras.itdb file and give myself permission to have full control.  THEN, I could go and estore a previos version.  Once I had done this, I got the same message for iTunes Library Genius.itdb . . . I did the same thing with it and Voila'!!
    Hope this helps...
    SVT

  • My search bar for my library no longer works. Also, the menu bar is no longer visible. Noticed this problem last Saturday. Can anyone help me with this?

    My search bar for my iTunes library no longer works. Also, the menu bar is no longer visible. Noticed this problem last Saturday. This might be an issue with my desktop, and not iTunes itself Can anyone help me with this?

    Press Ctrl-B to toggle the menu bar on and off.
    When you say that the "search bar for my iTunes library no longer works" can you be more specific?  The operation of the search function has changed in iTunes 12, essentially having two very distinct modes:
    when Search Entire Library is checked, entering a search string will generate a dropdown of all matching items within your whole library, from which multiple operations are available via context menus
    when Search Entire Library is unchecked, entering a search string creates a filtered view of whatever your current focus is (e.g., if you're looking at a playlist the filter applies only to items in that playlist) with none of the dropdown options as in the first case

  • I have updated to the new version of iPhoto but it will no longer let me edit text in the preset text boxes.  The text is highlighted for a nanosecond but will not stay highlighted so I can amend it.  Can anyone help me with this.  Many thanks.

    I have updated to the latest version of iPhoto.  But now iPhoto will not let me amend the preset text in the text boxes.
    the text is highlighted for a nano second but it will not stay highlighted so that I can add my own text.
    can anyone help me with this issue.
    Many thanks

    You might try using the add-on 'NoSquint' which allows numerous zoom options specific to each page you visit & keeps your settings - https://addons.mozilla.org/en-US/firefox/addon/nosquint/
    If you want to go back to 3.6x, you will find it here:
    http://www.mozilla.com/en-US/firefox/all-older.html
    In most cases you can simply "upgrade" (meaning downgrade) directly from the installation. It would be a good idea to save your passwords & bookmarks just to be on the safe side.

  • I have a Windows 7 Professional, 64 bits on my computer and have recently installed iTunes 11.1.3.8. but i started having this msg :"The folder iTunes is on a locked disk or you do not have write permission for this folder" issues: how can i solve it?

    I have a Windows 7 Professional, 64 bits on my computer and have recently installed iTunes 11.1.3.8. but i started having this msg :"The folder iTunes is on a locked disk or you do not have write permission for this folder" issues: how can i solve it?

    Right-click on your main iTunes folder and click Properties, then go to the Security tab and click Advanced. If necessary grant your account and SYSTEM full control of this folder, subfolders and files, then tick the option to replace permissions on child objects which will repair permissions throughout the library. This is the XP dialog but Windows 7 shouldn't be too different.
    If it won't let you change the permissions use the Owner tab to take ownneship from an account with administror privileges.
    tt2

Maybe you are looking for

  • Using family members non-data upgrade to get iPhone?

    My sister is available to upgrade her phone on February 3rd, 2011. That is the day you can preorder the iPhone 4 but I was wondering if I could use her upgrade (she already said I could) and get the iPhone for my line without adding a data plan for h

  • Itunes showing No sim Card issue while updating to ios 6.1

    Please help me out in upgrading my phone to IOS 6

  • Help!!!Can not turn on my Wifi on my macbook pro---tried everything---Help!!!

    I have a macbook pro a1286 early 2011 now, it is running mountain lion+Bootcamp windows 7 From last week, evertime i restart it, the wifi will be working for seconds or minites, after that it ll automaticlly turn off and i can not !!!TURN IT ON!!!!!

  • Authorization check confusion...

    Hello, I am trying to know about Authority-check. The security person has created authorization object  'zmsm00600'. This authorization object is used in one of the custom transaction code as follows: authority-check object 'zmsm00600' id 'ACTVT' fie

  • Authorizations For User Defined Forms

    Hi Experts !!! I have created a user form , and would like to apply authorization for that user form. Whether it is possible.I tried using standard method,but it seems that no such provision available , And also I have created UDT . and would like to