solveChallenge method

int solveChallenge([
  1. int step = 100,
  2. void callback(
    1. int hashPropagated
    )?
])

Implementation

int solveChallenge([int step = 100, void Function(int hashPropagated)? callback]){
  int? solvedRst;
  while(solvedRst == null){
    solvedRst = propagate(step);
    if(callback != null){
      callback(_nextNonce);
    }
  }
  return solvedRst;
}