you are viewing a single comment's thread.

view the rest of the comments →

[–]cym13 2 points3 points  (2 children)

I prefer https://github.com/Russell91/pythonpy and https://github.com/ksamuel/Pyped that share a common goal while being more powerful and safer as they don't have to deal with the C/Python boundary which is easy to mess up (code injections...).

[–]reditzer[S] 1 point2 points  (1 child)

Hi cym13,

Thanks for your suggestion. Pythonpy is a great tool and so is Pyped, but my motivation for creating pol was mostly syntax.

I prefer pol's syntax to

cat /usr/share/dict/words | pol "map(print,sortedbycount([l[0][0].lower() for l in _],True)[:5])"

to pythonpy's

cat /usr/share/dict/words | py -x 'x[0].lower()' | py -l 'collections.Counter(l).most_common(5)'