Skip to content

Instantly share code, notes, and snippets.

@joliss
Created December 26, 2013 00:28
Show Gist options
  • Save joliss/8128271 to your computer and use it in GitHub Desktop.
Save joliss/8128271 to your computer and use it in GitHub Desktop.
r = Math.random
for(y = c = ['']; y++ < 40;)
for(c[x = 0] += '\n'; x++ < 60; c[0] += '%c*')
c.push('background:#000;color:#' + (
y < 37 && (x < 30 ? x : 60 - x) + y * .7 - 3 > 30 ?
y < 6 || r() < 0.1 ? 'ffc' : 160 // branches + decoration
:
y > 36 && 27 < x && x < 33 ? // trunk
822
:
r() < .02 ? 332 : '000' // space + stars
))
console.log.apply(console, c)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment