Search:

Type: Posts; User: helloworld922

Search: Search took 0.34 seconds.

  1. Replies
    18
    Views
    2,190

    [SOLVED] Re: Return statement.

    Correct, printing is considered a "side effect".
  2. Replies
    18
    Views
    2,190

    [SOLVED] Re: Return statement.

    methods are there to help abstract your code. They follow the mentality of the "black box": I give you something, you give me something back. How you go from what I give you to what you give me I...
  3. Replies
    18
    Views
    2,190

    [SOLVED] Re: Return statement.

    The return statement returns values to be used in other code. println simply displays them to the console.

    ex.:
    // calculate x factorial
    public static int factorial(int x)
    {
    int result =...
Results 1 to 3 of 3