13
mab07
6y

Used a String as a Boolean
First sin of the year
😂😂😂
Ps:Android studio wont let me use int or boolean,it was suggesting to use respective arrays as it was inside a loop

Comments
  • 1
    Do yourself a big favor and use better descriptive variable names.

    Also, don't use == or != for string comparison in Java. Use the .equals() method.

    And still not sure why you're using string for Boolean. You just be doing something wrong.
  • 1
    @pbhoiwala Think you missed the point. Using == and <= is a common mistake for Java developer, especially after using a different language for a while.
Add Comment