Solve with callback