Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Somewhat tuned Rye solution #6

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Conversation

refaktor
Copy link

@refaktor refaktor commented Jan 21, 2025

You made a great Rye example! I just tried to tune it in a little more, and use some more already available (but some updated) functions like group and contains and unpack.

You also proposed intersection\by and sort\by, which I added to Rye now, but didn't use here at the end. Maybe because I still don't fully understand the algo :P. I think I understand everything, but that part about transformation related to possible squares eludes me, probably I need to do some more thinking :)

Anyhow, you said that we can post these and you will keep the PR open as additional info to examples. Great project!

Jared made a great example! I tried to tune it in a little more, and use some more already available (but updated) functions like `group` and `contains` and `unpack`. He also proposed intersection\by and sort\by , which I added to Rye, but didn't use here at the end. Maybe he can and make code even nicer :)
@refaktor refaktor changed the title A little updated and tuned Rye example Somewhat tuned Rye solution Jan 21, 2025
}

; Find anagrams from words file and keep transformations only
word-anagrams:
( split\quoted read %0098_words.txt "," `"` )
split\quoted read %0098_words.txt "," `"` ;"
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No :) .... Emacs Rye syntax highlighting did't detect the end of the string with "so it colored all next lines as string, this comment was small hack to stop that. I need to fix the highlighter.

@jaredkrinke
Copy link
Owner

Thanks! That looks like it's taking much better advantage of the built-ins!

@refaktor
Copy link
Author

Thanks! That looks like it's taking much better advantage of the built-ins!

Well, I did have to improve some of them (make them usable with blocks not just string for example) to make them usable here, so when you wrote the code you couldn't use them yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants