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: Method calls and Invocation

  1. #1
    Junior Member
    Join Date
    Aug 2012
    Posts
    6
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default Method calls and Invocation

    Hello there.. I have these questions taken from Intro To Java Programming by Y.Daniel Liang. I don't understand the question. Hope you will help me.

    Write method calls/method invocation for the following method definition:

    i. public void x (int y) {}

    ii. public int a () {return 100}

    iii. public double b(double c) {return 3.14}

    iv. public char d (String e) {return 'X'}

    v. public double cgpa (char grade) {return 3.9}

    vi. public int m (double n, char p) {return 0}


  2. #2
    Super Moderator Norm's Avatar
    Join Date
    May 2010
    Location
    Eastern Florida
    Posts
    25,042
    Thanks
    63
    Thanked 2,708 Times in 2,658 Posts

    Default Re: Method calls and Invocation

    If there are any questions or problems you have for each statement, please post them.
    Try doing what the question asks and post your code here with any error messages you get.
    Take them one at a time so there aren't too many error messages. Maybe after you write a couple you will see how its done.
    If you don't understand my answer, don't ignore it, ask a question.

  3. The Following User Says Thank You to Norm For This Useful Post:

    curmudgeon (August 24th, 2012)

Similar Threads

  1. Problems With Method Calls and Variables
    By connor3452 in forum What's Wrong With My Code?
    Replies: 2
    Last Post: May 17th, 2012, 05:46 AM
  2. Timer expiry calls a method
    By jack_nutt in forum Java Theory & Questions
    Replies: 1
    Last Post: July 11th, 2011, 07:46 PM
  3. Case statements to Method calls???
    By Java Neil in forum Java Theory & Questions
    Replies: 1
    Last Post: February 24th, 2011, 06:17 AM
  4. Need help understanding method calls and such
    By hackman2007 in forum Java Theory & Questions
    Replies: 8
    Last Post: July 14th, 2010, 08:18 AM
  5. Any way to map method calls?
    By Swiftslide in forum Collections and Generics
    Replies: 1
    Last Post: September 21st, 2009, 04:37 AM