Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 2 of 2

Thread: Java Programming

  1. #1
    Junior Member
    Join Date
    Mar 2013
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Java Programming

    The test program needs to create a StateTaxableWorker object and a LocalTaxableWorker object. The test program must contain a display method which takes a base class TaxableWorker object reference along with the number of hours worked by the worker. The display method should use the base class workerInfo method to get the name and tax information about the worker and output that information. The display method should also use the base class grossPay method to get the pay info for the worker and display that information. Then the display method should use the taxWithheld method to output the total amount of tax withheld for the worker.

    The test program should pass the StateTaxableWorker object and the LocalTaxableWorker object to the display method along with the number of hours each worker has worked. The output seen should demonstrate polymorphic behavior, that is the base class TaxableWorker reference to a StateTaxableWorker object elicits StateTaxableWorker tax information and correct tax withheld, and the base class TaxableWorker reference to a LocalTaxableWorker object elicits LocalTaxableWorker tax information and correct tax withheld.


  2. #2
    Member angstrem's Avatar
    Join Date
    Mar 2013
    Location
    Ukraine
    Posts
    200
    My Mood
    Happy
    Thanks
    9
    Thanked 31 Times in 29 Posts

    Default Re: Java Programming

    Where particularly do you have problems? Please show us the code you've tried.

Similar Threads

  1. Replies: 1
    Last Post: January 6th, 2013, 06:32 AM
  2. can you pls help me in this java programming? code=java
    By srivani in forum What's Wrong With My Code?
    Replies: 1
    Last Post: December 25th, 2012, 02:31 AM
  3. android programming vs game programming using java
    By vgoel38 in forum Android Development
    Replies: 4
    Last Post: September 8th, 2012, 05:48 PM
  4. Replies: 0
    Last Post: December 12th, 2011, 03:17 PM
  5. Is java a power full programming language? can java do this?
    By Jhovarie in forum Java Theory & Questions
    Replies: 5
    Last Post: March 2nd, 2011, 02:02 PM