Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Pretty Print Tree Data Structures in Common Lisp
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@lispm
Copy link

lispm commented Feb 20, 2020

That's nice! Well done!

Btw.:

  • you can get rid of the (APPLY #'NCONC ...) if you APPEND in the LOOPs, instead of COLLECT.

  • it's usually better to put a WITH clause before all the FOR clauses

  • one can also write FOR (head . tail) ON lower-children

@vseloved
Copy link

@WetHat
Copy link
Author

WetHat commented Feb 20, 2020 via email

@WetHat
Copy link
Author

WetHat commented Feb 20, 2020

Hi lispm,

Your suggestions are very much appreciated! I'll look into them as soon as I can.

  • you can get rid of the (APPLY #'NCONC ...) if you APPEND in the LOOPs, instead of COLLECT.
  • it's usually better to put a WITH clause before all the FOR clauses
  • one can also write FOR (head . tail) ON lower-children

@vseloved
Copy link

Thanks for the pointer to svgbob. I'm collecting such references. A great list of different ASCII and similar visualization tools is crowdsourced here: https://twitter.com/SusanPotter/status/1189165775275331584

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment