Search:

Type: Posts; User: simpson_121919

Search: Search took 0.09 seconds.

  1. Replies
    3
    Views
    1,095

    Re: Cannot pass variables?

    Oh, so to make the swap method work I would have to create public variable which is bad design practice?
  2. Replies
    3
    Views
    1,095

    Cannot pass variables?

    in my instance field I have variables a = 1 and b = 2. I can not seem to pass "a" and "b" through my swap method as a parameter. I am confused to why.


    public void swap(int i1, int i2)
    ...
Results 1 to 2 of 2