People who code: we want your input. Take the Survey
6 of 13
added 286 characters in body

JavaScript (ES6), 312, 285, 281

Edit: Saved a bunch of bytes by replacing all the runs of four zeros (0000) by A and all 00zs by B and afterwards replacing them back. While doing that, I optimized the replace method call furiously.

Edit 2: In an earlier version I needed the parantheses; I removed them. Also, replaced x=='A' by x<'B' and a==… by a<'!', because at least JavaScript’s string comparison is awesome!

Runnable in Firefox 39:

c03200320iBB20izBss000lssB445i00c0320iB44004z4`.replace(/A|B/g,x=>x<'B'?'0000':'00z')].map(a=>a<'!'?a:' -/\\_|'[n%2?parseInt(a,36)%6:~~(parseInt(a,36)/6)]).join``

// Testing:


It’s based on the base 6 number system and each ASCII character stands for a number:

" ": 0
"-": 1
"/": 2
"\": 3
"_": 4
"|": 5

Then, I’ve combined the number representation of each ASCII string. For example: when the first ASCII string contains a / at one position and the other one contains a \ at the same position, that position becomes 32, which is base 6 (20 in decimal). If you convert this to base 36 (to get one base-36 number for every two base-6 numbers), you get k.

All this was done beforehand and the function basically undoes this process.

Now the two JavaScript answers both have one other answer each, that has the same byte count…

PS: As a note to myself and a reference to others, this is the code I used:

// 1. ASCII here
a=`|\\-/ _`;

// 2. ASCII here
b=`/|\\_ -`;

    .replace(/ /g,'0')
// Returns "wn9g0p", which is then put into the function as the block at the top.