java - Using boolean flag -


i not sure how change inside of if statement in code fragment below reflect false.

matches boolean method

if (toppilecard.matches(super.getcardfromhand(i))) {     tempcardarray[i] = super.getcardfromhand(i);  } 

the easiest way include exclamation mark ! @ beginning of condition statement:

if (!toppilecard.matches(super.getcardfromhand(i))) {     tempcardarray[i] = super.getcardfromhand(i);  } 

in java, ! can used mean false or not. example, != comparator means "not equal to", opposed == means "equal to".


Comments

Popular posts from this blog

php - Hide output during test execution -

javascript - Migrate custom AngularJS filter from 1.2.28 to 1.4.x -

Update Magento products with multiple images -