evinism / lambda-explorer

Tutorial / REPL for the lambda calculus
https://lambdaexplorer.com/
MIT License
61 stars 9 forks source link

General feedback #62

Open azala opened 5 years ago

azala commented 5 years ago

I met you at the JS meetup last week and you showed me Lambda Explorer.

I'm surprised it got no attention on Hacker News when you posted it 4 years ago. Maybe it sucked back then. This sounds exactly like something they would like and it's better than every other lambda calculus interpreter/tutorial I found in a google search.

I finished it up to the 3 challenge problems (still working on them), here are my notes:

Extremely nitpicky things that you don't have to fix at all

Again, these are all nitpicks and you did a great job! I don't think I would have bothered learning lambda calculus if the interpreter were not this fun to play with.

evinism commented 5 years ago

Oh hot damn, these are a good list of suggestions!

Let's see if I can respond to all of these: 1: Thanks, i suck at spelling

2: I've never considered! Should be super easy and rather pleasant. Will do, because it takes like 0 time to implement.

3: Will def increase their size. I'm considering doing a small restyle for them anyways, where they take up the entire width of the side panel. Should be a lot more obvious.

4: Noted, I'll try to do a revamp of this. One of the things the tutorial has been severely lacking is diagrams. It would help SO MUCH with the first few problems, and it'd certainly be helpful for normal order explanations too.

5: As in, moving all but the 0th church numeral to be secret, I assume? I'm a little surprised with this piece of feedback, to be honest. I figured showing all the representations in front of you at once lets you see the pattern really clearly.

6: Sure, why not!

7: I've been considering some way of doing this for a while, along with also seeing what's been defined already. I'm thinking the best solution is to just persist everything and give granular options to clear everything in like a gear icon.

As for nitpicks: 1: This makes a lot of sense, and I have no reason to not do that, except MAYBE it being weird with the all-caps w/ the lexer.

2: This is technically undecidable. I could do it for either a truth table or for a few standard forms, but i decided on just not doing it for functions.

3: This is certainly on my radar. It's blocked on a number of things, most recently #60. The point is, my method of avoiding collisions is by using a special character that users can't input, and globally increment a counter. This is obviously a garbage solution, but solving it requires the engine to be aware of what's in scope vs. not. This is by far teh biggest limitation of the engine so far and solving it allows for a lot of neat things.

Thank you so much for all this feedback. This has to be the best group of suggestions I've ever received-- you've obviously put a bunch of thought into this.

azala commented 5 years ago

Re: 5 - Once you have the representations for 0 and 1, the rest are trivial to derive.

As a problem-solving masochist, I wanted to try and play around to sort of "guess" what the representation of 1 was, given the representation of 0 and everything I had learned to that point.

It's probably fine if you leave 0 and 1 shown and the rest hidden.

evinism commented 5 years ago

Dark theme pr here: https://github.com/evinism/lambda-explorer/pull/63, gonna merge momentarily

azala commented 5 years ago

Dark theme works great except links (still blue/purple)

evinism commented 5 years ago

ah, for sure-- not sure quite where you're talking about; might be browser specific. Wanna make a separate issue documenting it? (e.g. exactly where / what browser)

azala commented 5 years ago

https://github.com/evinism/lambda-explorer/issues/69