Search:

Type: Posts; User: helloworld922

Search: Search took 0.07 seconds.

  1. Replies
    5
    Views
    4,323

    Re: Java Code Help - Calling Method

    Oh duh... I forgot about that. Add the keyword 'static' to your method signatures

    public static double cube(double value)
    public static double square(double value)

    the static keyword means you...
  2. Replies
    5
    Views
    4,323

    Re: Java Code Help - Calling Method

    haha, i wasn't reading carefully :)

    it should be this:


    // get the value squared
    double squared = square(entry);
    // print it out
    ...
  3. Replies
    5
    Views
    4,323

    Re: Java Code Help - Calling Method

    Simple, in fact you're already calling a few methods in your code. They just happen to be methods you didn't write :)

    The general from:

    method_name(method_parameters)

    method_name is the name...
Results 1 to 3 of 3