Search:

Type: Posts; User: copeg

Search: Search took 0.09 seconds.

  1. Replies
    6
    Views
    1,345

    Re: Dont know whats happening

    Pass references of the variables to the printDetails method. You have to reform the method declaration to accept the variables


    public static void printDetails(Food food1, Food food2){
    ...
    ...
  2. Replies
    6
    Views
    1,345

    Re: Dont know whats happening

    Study the link I posted above. Remove the statics from all the functions and variables and access them through an instance.


    CheddarCheese cc = new CheddarCheese(//with arguments//);...
  3. Replies
    6
    Views
    1,345

    Re: Dont know whats happening

    For future reference, please flank your code with the or the code tags. I've edited your post to account for this.

    All the variables are static, meaning if they change for one they change for...
Results 1 to 3 of 3