mirror of
https://github.com/jaysavsani07/math-metrix.git
synced 2025-08-06 15:11:40 +08:00
math grid print removed
This commit is contained in:
@ -64,11 +64,8 @@ class MathGridProvider with ChangeNotifier {
|
|||||||
|
|
||||||
var listOfUnRemovedIndex = _currentState.listForSquare.where((result) => result.isRemoved == false).toList();
|
var listOfUnRemovedIndex = _currentState.listForSquare.where((result) => result.isRemoved == false).toList();
|
||||||
if (listOfUnRemovedIndex.length <= 12) {
|
if (listOfUnRemovedIndex.length <= 12) {
|
||||||
print("less then 10");
|
|
||||||
var possiblePairs = getCountOfPossiblePairs(listOfUnRemovedIndex, _currentState.currentAnswer);
|
var possiblePairs = getCountOfPossiblePairs(listOfUnRemovedIndex, _currentState.currentAnswer);
|
||||||
print("possible pairs : $possiblePairs");
|
|
||||||
_index = _index + 1 ;
|
_index = _index + 1 ;
|
||||||
print("_index + $_index");
|
|
||||||
_currentState = _list[_index];
|
_currentState = _list[_index];
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -87,7 +84,7 @@ class MathGridProvider with ChangeNotifier {
|
|||||||
for (int i = 0; i < listOfIndex.length; i++) {
|
for (int i = 0; i < listOfIndex.length; i++) {
|
||||||
total = total + listOfIndex[i].value;
|
total = total + listOfIndex[i].value;
|
||||||
}
|
}
|
||||||
print("total $total");
|
|
||||||
if (_currentState.currentAnswer == total) {
|
if (_currentState.currentAnswer == total) {
|
||||||
for (int i = 0; i < listOfIndex.length; i++) {
|
for (int i = 0; i < listOfIndex.length; i++) {
|
||||||
listOfIndex[i].isActive = false;
|
listOfIndex[i].isActive = false;
|
||||||
@ -95,8 +92,8 @@ class MathGridProvider with ChangeNotifier {
|
|||||||
}
|
}
|
||||||
currentScore = currentScore + ScoreUtil.mathMachineScore;
|
currentScore = currentScore + ScoreUtil.mathMachineScore;
|
||||||
answerIndex = answerIndex + 1;
|
answerIndex = answerIndex + 1;
|
||||||
print("answer indiex $answerIndex");
|
|
||||||
print("list of answer legnth ${_currentState.listOfAnswer.length}");
|
|
||||||
_currentState.currentAnswer = _currentState.listOfAnswer[answerIndex];
|
_currentState.currentAnswer = _currentState.listOfAnswer[answerIndex];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user