Search:

Type: Posts; User: Norm

Search: Search took 0.22 seconds.

  1. Replies
    20
    Views
    1,415

    Re: Instance variable inside a method

    The break; statement will cause execution to exit the loop.
    What is the value of charges? Add a println statement and print out its value.
  2. Replies
    20
    Views
    1,415

    Re: Instance variable inside a method

    These very basic concepts seem to be past your current knowledge. I suggest you work with a small program to learn how to create instances of classes and access their methods and variables. Work...
  3. Replies
    20
    Views
    1,415

    Re: Instance variable inside a method

    This code creates an instance of the WebHost class:

    WebHost webHost = new WebHost();
    The variable: webHost refers to the instance of the class that was created by the new statement.

    Is there...
  4. Replies
    20
    Views
    1,415

    Re: Instance variable inside a method

    Ok, forget about the shipping variable for now. If the two variables you want: highest and lowest are defined in the WebHost class, we'll move on to the third question:

    Does the class that the...
  5. Replies
    20
    Views
    1,415

    Re: Instance variable inside a method

    Where is the variable: shipping defined in that class?
  6. Replies
    20
    Views
    1,415

    Re: Instance variable inside a method

    What class are those variables defined in?
  7. Replies
    20
    Views
    1,415

    Re: Instance variable inside a method

    You skipped answering the questions I asked in post#6. Can you look at them and answer them?

    I'll ask them 0ne at a time if three are too many:
    What variables hold the values you want to print...
  8. Replies
    20
    Views
    1,415

    Re: Instance variable inside a method

    What variables hold the values you want to print in the computeShippingCharges() method?
    What class are those variables located in?

    Does the class that the computeShippingCharges() method is in...
  9. Replies
    20
    Views
    1,415

    Re: Instance variable inside a method

    When you say display, do you mean to use the println() statement to display the values on the console?

    What are the names of the variables with the values you want to display? What class are they...
  10. Replies
    20
    Views
    1,415

    Re: Instance variable inside a method

    What values in what variables in what class do you want methods in other classes to have access to?
Results 1 to 10 of 10