Skip to content

Instantly share code, notes, and snippets.

@Spuffynism
Created September 25, 2018 14:34
Show Gist options
  • Save Spuffynism/c0579545919b2c149b419e1654b9b84f to your computer and use it in GitHub Desktop.
Save Spuffynism/c0579545919b2c149b419e1654b9b84f to your computer and use it in GitHub Desktop.
Sudoku semi validator
function validSolution(b){
return f=x=>x.map(v=>eval(v.join`+`)),[...f(b),...f(b[0].map((c,i)=>b.map(r=>r[i])))].every(v=>v==45)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment