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

koans 19 datatypes, last meditation solution #154

Closed
fmesnata opened this issue Dec 13, 2019 · 1 comment
Closed

koans 19 datatypes, last meditation solution #154

fmesnata opened this issue Dec 13, 2019 · 1 comment

Comments

@fmesnata
Copy link

Since I couldn't find the solution for the last meditation of the datatype koan, I checked the solution and I was a bit suprised to find only :

(str "Congratulations on your Best Picture Oscar, "
                          "Evil Alien Conquerors!")

So we shouldn't use category and recicpient here?

With auto-completion, I found this solution :

(print (str "You're really the "
                (.-category this) ", "
                recipient
                "... sorry."))

Shouldn't it be the solution here?
Do the explaination for .- syntax comes later?

@trptcolin
Copy link
Member

Ah, I see where the confusion is: those solutions aren't in order of the koans that are presented - they're in the order of the blanks in the file. So the solution you're looking for to solve that last koan in the file corresponds to the first blank in that file, which is really similar to what you have there, except using .category instead of .-category. FWIW I don't think I've ever used the .-category syntax in JVM Clojure (though I recall doing that in ClojureScript).

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

No branches or pull requests

2 participants