logo
  • Start here
  • Episodes
  • Articles
  • Log in
  • Sign up

Deck generation, Pythagorean Triplets and more

Topics:
Sigils
Codepoints
Filters
Generators
Comprehensions

Using comprehensions to generate a deck of cards was the challenge at the end of last lesson. Here we solve that and play around with comprehensions to do some other things such as generating binaries, filtering characters out of them, and generating Pythagorean Triplets (integers that are the lengths of sides of right triangles).

Language features introduced: ? syntax for getting a character's codepoint, comprehension filters, the ~w sigil

Share

Request a free email course
Back to index

No Comments

Log in to leave a comment
Alchemist Camp 2017-2020
Hosted on Digital Ocean
Terms and Conditions