Skip to content
master
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 

README.md

Theseus

Creating and solving a maze in only 256 bytes of JavaScript.



    ,@,@,@,@,@,@,@,@,@,@,@,
    ,+,+,+,+,+,+,@, , , ,@,
    ,@, ,@,@,@,+,@, ,@, ,@,
    ,@, ,@,+,+,+,@, ,@, ,@,
    ,@,@,@,+,@,@,@,@,@, ,@,
    ,@,+,+,+,@, , , , , ,@,
    ,@,+,@,@,@,+,@, ,@,@,@,
    ,@,+,@, , ,+,@, ,@, ,@,
    ,@,+,@,@,@,+,@, ,@, ,@,
    ,@,+,+,+,+,+,@, , , ,@,
    ,@,@,@,@,@,@,@,@,@,@,@

Minimal Source (256 bytes):

for(z=[c=66,i=132];i--;X=a=>_.map((b,e)=>
1<z[b=a+2*_[3&e+i]]&&X(b,i=9*Math.random(
z[b]=z[(a+b)/2]=F=0))))_=[-12,z[i]=i%12?5
:-1,12,1];for(X(14);F<2;F?0:$=[...z],$[13
]=$[c]=4)c^14?z[c]=z[c]+~F&3:c=++F&&66,5>
z[n=c+_[z[c]]]&&(c=n);""+$.map(b=>`
    +@`[++b])

Links

About

Creating and solving a maze in only 256 bytes of JavaScript.

Resources

Releases

No releases published

Packages

No packages published
You can’t perform that action at this time.