McEs, A Hacker Life
On Python Coolness
: Your hack only works if input sequence holds boolean (or integers for that matter) only. Note that Iverson’s Convention only says that the a boolean result
is encoded as 0 or 1.
There is an elegant solution to your puzzle: use another lambda
to work around and
all = lambda seq: reduce(lambda a, b: a and b, seq, True)
Moreover, unlike the Iverson
page you linked to claims, at least with Python 2.5, Python does not use Iversion, but does the Perl-style convention of returning the first operand that determined the outcome of the expression, taking the short-circuit rules in mind:
>>> "m" and "n"
>>>  and True
Labels: Iverson, python, wingo
The Most Beautiful Persian OpenType Font
Glad I asked for it last month
Apparently the Supreme Council of ICT of Iran
has released the first ever OpenType Persian Nastaliq
font. This is of great importance because previously all Persian Nastaliq solutions were Windows-only systems requiring custom rendering engine installed and only worked with select applications. Not anymore!
Anyway, very nice outcome of a governmental-funded project in Iran. I quite appreciate that. The font can be downloaded here
Now to the interesting part. Again, Pango 1.18.3 and gedit:
The font itself is far from perfect in its OpenType tables, but it's a great start. I've been wanting that for so long... The only issue is that the font doesn't hold a clear license. Got to sort that out and voila! I know, I'm clearly excited. Very excited.
Labels: gedit, gnome, harfbuzz, IranNastaliq, Nastaliq, pango, Persian
Life Goes On in Iran
Hard times being an Iranian, but many of us want to let the world know that no matter what our president
says, no matter what your president
says, life goes on in Iran, and the Iranian people live and think pretty normal lives/thoughts.
Here are a couple of photo collections of Iran for your eyes' pleasure:
Sun over the Lake at Soleyman-tange Dam around my home city of Sari, Iran
Labels: Iran, photos, sari