Ever-growing remake of the classic 15 square puzzle. Solve the puzzle to unlock the next size. How many can you solve?
b.innerHTML += '<span id=play></span><style>#c{display:none}div{width:25px;float:left;border:1px solid #000;text-align:center;margin:1px}.b{border-color:#FFF}.r{background:#A00;color:#FFF}</style>';q=3;n=[];function m(){document.body.style.width=q*30+"px";w=q*q-1;x=w;n=[];for(i=0;i<w;i++){r=(Math.random()*w)|0;t=n[r]?n[r]:r+1;n[r]=n[i]?n[i]:i+1;n[i]=t}y=0;for(i=0;o=n[i],i<w;i++)for(j=i+1;p=n[j],j<w;j++)y+=p<o?1:0;if(y%2==1)m();n[w]=0}function d(){p=document.getElementById("play");p.innerHTML="";for(i in n){o=n[i]==0?' ':n[i];p.innerHTML+="<div "+c(o)+">"+o+"</div>"}}function s(o){a=x;if(o==0)x--;if(o==1)x-=q;if(o==2)x++;if(o==3)x+=q;t=n[a];n[a]=n[x];n[x]=t;d()}addEventListener("keydown",function(e){k=e.keyCode-37;if((k==0&&x%q>0)||(k==1&&x>=q)||(k==2&&x%q<q-1)||(k==3&&x<q*q-q))s(k);if(x==w){for(i=0;i<w-1;i++){if(n[i]>n[i+1])return;}alert("YOU WIN!");q++;m();d()}},!1);function c(o){if(o%2==1)return 'class="r"';if(o==" ")return 'class=b';return ""}m();d()
Yi5pbm5lckhUTUwgKz0gJzxzcGFuIGlkPXBsYXk+PC9zcGFuPjxzdHlsZT4jY3tkaXNwbGF5Om5vbmV9ZGl2e3dpZHRoOjI1cHg7ZmxvYXQ6bGVmdDtib3JkZXI6MXB4IHNvbGlkICMwMDA7dGV4dC1hbGlnbjpjZW50ZXI7bWFyZ2luOjFweH0uYntib3JkZXItY29sb3I6I0ZGRn0ucntiYWNrZ3JvdW5kOiNBMDA7Y29sb3I6I0ZGRn08L3N0eWxlPic7cT0zO249W107ZnVuY3Rpb24gbSgpe2RvY3VtZW50LmJvZHkuc3R5bGUud2lkdGg9cSozMCsicHgiO3c9cSpxLTE7eD13O249W107Zm9yKGk9MDtpPHc7aS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