<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Programming on Lorenzo Bolla</title><link>https://lbolla-info.netlify.app/tags/programming/</link><description>Recent content in Programming on Lorenzo Bolla</description><generator>Hugo</generator><language>en-us</language><lastBuildDate>Fri, 02 Dec 2022 00:00:00 +0000</lastBuildDate><atom:link href="https://lbolla-info.netlify.app/tags/programming/index.xml" rel="self" type="application/rss+xml"/><item><title>Python MRO surprises</title><link>https://lbolla-info.netlify.app/blog/python-mro-surprises/</link><pubDate>Fri, 02 Dec 2022 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/python-mro-surprises/</guid><description>&lt;p&gt;Consider a script like this:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-python" data-lang="python"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;class&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;A&lt;/span&gt;:
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;def&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;__init__&lt;/span&gt;(self):
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; print(&lt;span style="color:#e6db74"&gt;&amp;#39;a&amp;#39;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;class&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;B&lt;/span&gt;:
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;def&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;__init__&lt;/span&gt;(self):
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; print(&lt;span style="color:#e6db74"&gt;&amp;#39;b&amp;#39;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;class&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;C&lt;/span&gt;(A, B):
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;def&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;__init__&lt;/span&gt;(self):
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; super()&lt;span style="color:#f92672"&gt;.&lt;/span&gt;&lt;span style="color:#a6e22e"&gt;__init__&lt;/span&gt;()
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; print(&lt;span style="color:#e6db74"&gt;&amp;#39;c&amp;#39;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;C()
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;What will it output? If you are like me, you would answer, without much thought, that it prints:&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;a
c
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;To work it out you need to know about Python's MRO (Method Resolution Order): &lt;a href="https://medium.com/@__hungrywolf/mro-in-python-3-e2bcd2bd6851"&gt;this article&lt;/a&gt; provides a clear explanation of how it works. In this case, we have:&lt;/p&gt;</description></item><item><title>gio in cronjob</title><link>https://lbolla-info.netlify.app/blog/gio-in-cronjob/</link><pubDate>Mon, 14 Dec 2020 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/gio-in-cronjob/</guid><description>&lt;p&gt;&lt;a href="https://developer.gnome.org/gio/stable/gio.html"&gt;gio&lt;/a&gt; provides a nice API to deal with VFS. I am using it to mount a NAS harddrive to use for backups.&lt;/p&gt;
&lt;p&gt;The problem is that using it from cronjobs is not straightfoward. I got the following errors when trying to run &lt;code&gt;gio info&lt;/code&gt; and &lt;code&gt;gio mount&lt;/code&gt; from a cronjob:&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;gio: smb://internetbox-nas.local/philips%20ufd/: Operation not supported
gio: smb://internetbox-nas.local/philips%20ufd/: volume doesn’t implement mount
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;I didn't find the right answer in Google, so I am sharing it here in case someone else is affected.&lt;/p&gt;</description></item><item><title>Goodbye Linode, welcome AWS!</title><link>https://lbolla-info.netlify.app/blog/goodbye-linode-welcome-aws/</link><pubDate>Fri, 11 Dec 2020 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/goodbye-linode-welcome-aws/</guid><description>&lt;p&gt;After many years of service, I decided to move away from &lt;a href="https://www.linode.com/"&gt;Linode&lt;/a&gt;. Linode has been hosting this website and my backups flawlessly and gave me my first introduction to Cloud computing back when it wasn't so widespread.&lt;/p&gt;
&lt;p&gt;Since then, many new players have joined the cloud computing space and few big players have come up on top. Amazon AWS is obviously one of them. I decided to go with them over Linode for a couple of reasons.&lt;/p&gt;</description></item><item><title>Impl specialization in Rust</title><link>https://lbolla-info.netlify.app/blog/impl-specialization-in-rust/</link><pubDate>Sat, 11 Apr 2020 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/impl-specialization-in-rust/</guid><description>&lt;p&gt;Yesterday I learnt about a feature in Rust, currently only available in nightly: &lt;a href="https://github.com/rust-lang/rfcs/pull/1210"&gt;impl specialization&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I had to solve the problem highlighted in the following snippet:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-rust" data-lang="rust"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;use&lt;/span&gt; std::hash::Hash;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;trait&lt;/span&gt; Foo {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;fn&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;get_foo&lt;/span&gt;(&lt;span style="color:#f92672"&gt;&amp;amp;&lt;/span&gt;self) -&amp;gt; String;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;}
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;impl&lt;/span&gt;&lt;span style="color:#f92672"&gt;&amp;lt;&lt;/span&gt;T: &lt;span style="color:#a6e22e"&gt;Hash&lt;/span&gt;&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; Foo &lt;span style="color:#66d9ef"&gt;for&lt;/span&gt; T {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;fn&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;get_foo&lt;/span&gt;(&lt;span style="color:#f92672"&gt;&amp;amp;&lt;/span&gt;self) -&amp;gt; String {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#e6db74"&gt;&amp;#34;foo for hash&amp;#34;&lt;/span&gt;.to_string()
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; }
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;}
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;impl&lt;/span&gt; Foo &lt;span style="color:#66d9ef"&gt;for&lt;/span&gt; String {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;fn&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;get_foo&lt;/span&gt;(&lt;span style="color:#f92672"&gt;&amp;amp;&lt;/span&gt;self) -&amp;gt; String {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#e6db74"&gt;&amp;#34;foo for string&amp;#34;&lt;/span&gt;.to_string()
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; }
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;}
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;fn&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;main&lt;/span&gt;() {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;let&lt;/span&gt; bar: String &lt;span style="color:#f92672"&gt;=&lt;/span&gt; &lt;span style="color:#e6db74"&gt;&amp;#34;bar&amp;#34;&lt;/span&gt;.to_string();
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#a6e22e"&gt;println!&lt;/span&gt;(&lt;span style="color:#e6db74"&gt;&amp;#34;&lt;/span&gt;&lt;span style="color:#e6db74"&gt;{}&lt;/span&gt;&lt;span style="color:#e6db74"&gt;&amp;#34;&lt;/span&gt;, bar.get_foo());
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;let&lt;/span&gt; baz: &lt;span style="color:#66d9ef"&gt;i32&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;1&lt;/span&gt;;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#a6e22e"&gt;println!&lt;/span&gt;(&lt;span style="color:#e6db74"&gt;&amp;#34;&lt;/span&gt;&lt;span style="color:#e6db74"&gt;{}&lt;/span&gt;&lt;span style="color:#e6db74"&gt;&amp;#34;&lt;/span&gt;, baz.get_foo());
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;}
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Compiling this code gives the below error:&lt;/p&gt;</description></item><item><title>Nice threads in Python</title><link>https://lbolla-info.netlify.app/blog/nice-threads-in-python/</link><pubDate>Sat, 01 Feb 2020 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/nice-threads-in-python/</guid><description>&lt;p&gt;Python has two ways to execute code in parallel: processes and threads. Both have their strengths and weaknesses. In particular, threads are cheaper in terms of resources and are able to share memory, but besides the obvious pitfalls of multi-threaded programming, they suffer from some Python specific problems, notably:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Because of the GIL, only one Python's thread is actually running at any one time. So, very little parallelism is possible if the task is CPU bound. In fact, more often than not, it's more efficient to execute multiple tasks sequentially on a single thread (pinned to a single CPU), rather than spawning multiple threads and having the Python interpreter context switching too much and not being able to schedule the threads on all available CPUs.&lt;/p&gt;</description></item><item><title>Speeding up Oh-my-zsh</title><link>https://lbolla-info.netlify.app/blog/speeding-up-oh-my-zsh/</link><pubDate>Sun, 20 May 2018 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/speeding-up-oh-my-zsh/</guid><description>&lt;p&gt;Today I read a &lt;a href="https://blog.jonlu.ca/posts/speeding-up-zsh"&gt;very interesting article&lt;/a&gt; about speeding up &lt;a href="https://github.com/robbyrussell/oh-my-zsh"&gt;Oh-my-zsh&lt;/a&gt;. So, I tried to profile my own startup times and I discovered that:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Zsh start time was about 500ms&lt;/li&gt;
&lt;li&gt;Bash start time is less than 10ms&lt;/li&gt;
&lt;li&gt;Zsh (without config) start time is less than 10ms&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Most of startup time was spent loading 3 plugins that I regularly use:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;emacs&lt;/code&gt;, which provides handy aliases to interact with Emacs daemon. I was surprised this plugin was slow because it just defines a bunch of aliases. It turns out that it was spending 50+ ms checking Emacs' version (by starting up Emacs every time). I sped it up considerably by instead checking &lt;code&gt;emacsclient&lt;/code&gt; version. &lt;a href="https://github.com/robbyrussell/oh-my-zsh/issues/6840"&gt;PR submitted&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;kubectl&lt;/code&gt;, which provides aliases and completion for &lt;code&gt;kubectl&lt;/code&gt;. It turns out that it was spending 200+ ms to generate the completion script using &lt;code&gt;kubectl completion zsh&lt;/code&gt; every single time. I sped it up by caching the completion script, that is not subject to change very often. &lt;a href="https://github.com/robbyrussell/oh-my-zsh/pull/6844"&gt;PR submitted&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;virtualenvwrapper&lt;/code&gt;, which sources &lt;code&gt;virtualenvwrapper.sh&lt;/code&gt; and little more. Virtualenvwrapper also supports a &amp;quot;lazy&amp;quot; version of its script, so I sped up startup times by preferring the &amp;quot;lazy&amp;quot; script to the &amp;quot;eager&amp;quot; one. &lt;a href="https://github.com/robbyrussell/oh-my-zsh/pull/6842"&gt;PR submitted&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I hope the above 3 PRs will be approved and merged!&lt;/p&gt;</description></item><item><title>Edit Kubernetes secrets</title><link>https://lbolla-info.netlify.app/blog/edit-kubernetes-secrets/</link><pubDate>Sun, 14 Jan 2018 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/edit-kubernetes-secrets/</guid><description>&lt;p&gt;&lt;a href="https://kubernetes.io/"&gt;Kubernetes&lt;/a&gt; secrets are difficult to edit using standard command line tools, like &lt;code&gt;kubectl&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;When doing &lt;code&gt;kubectl edit secret my-secret&lt;/code&gt; you are presented with a base64-encoded blob that you have to first decode, in order to edit it and then re-encode before saving the file.&lt;/p&gt;
&lt;p&gt;There are various ways to deal with it, but none is user-friendly, in my opinion. Therefore, I wrote &lt;a href="https://github.com/lbolla/kube-secret-editor"&gt;kube-secret-editor&lt;/a&gt;: a simple Python script to decode and encode secret values on the flight before/after editing.&lt;/p&gt;</description></item><item><title>Kubectl outdated plugin</title><link>https://lbolla-info.netlify.app/blog/kubectl-outdated-plugin/</link><pubDate>Thu, 04 Jan 2018 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/kubectl-outdated-plugin/</guid><description>&lt;p&gt;We use &lt;a href="https://kubernetes.io/"&gt;Kubernetes&lt;/a&gt; at &lt;a href="https://yougov.co.uk/"&gt;work&lt;/a&gt; and I am mostly responsible for making it run smoothly. This means staying on top of new releases, libraries and tools that come out at a pace I've never experienced before, in any project.&lt;/p&gt;
&lt;p&gt;To help with that, I wrote a &lt;a href="https://kubernetes.io/docs/tasks/extend-kubectl/kubectl-plugins/"&gt;kubectl plugin&lt;/a&gt; that finds outdated components in a Kubernetes cluster. The &lt;strong&gt;&lt;a href="https://github.com/lbolla/kubectl-plugin-outdated"&gt;code can be found here&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;It works like this.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;First it goes through all &lt;code&gt;deployments&lt;/code&gt; and &lt;code&gt;daemonsets&lt;/code&gt;, collecting the &lt;code&gt;images&lt;/code&gt; referenced in their &lt;code&gt;containers&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;For each container, search for a newer image &lt;em&gt;tag&lt;/em&gt; in its repository. I currently support querying Docker Hub and Google Container Repository (you need &lt;a href="https://cloud.google.com/sdk/gcloud/"&gt;gcloud&lt;/a&gt; for that).&lt;/li&gt;
&lt;li&gt;Outputs which deployment or daemonset needs upgrading.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;E.g. running it on a testing cluster I setup gives this output:&lt;/p&gt;</description></item><item><title>org-based lbolla.info</title><link>https://lbolla-info.netlify.app/blog/org-based-lbolla.info/</link><pubDate>Thu, 04 Jan 2018 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/org-based-lbolla.info/</guid><description>&lt;p&gt;&lt;a href="https://lbolla.info"&gt;lbolla.info&lt;/a&gt; is now written in &lt;a href="http://orgmode.org/"&gt;Org&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I use &lt;code&gt;org-mode&lt;/code&gt; daily for all sorts of tasks:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;TODO list&lt;/li&gt;
&lt;li&gt;Keeping tracks of meetings, events, etc.&lt;/li&gt;
&lt;li&gt;Note taking&lt;/li&gt;
&lt;li&gt;Presentations&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;It was annoying to have to switch to another markdown language for blogging. So, I looked into &lt;a href="https://orgmode.org/worg/org-tutorials/org-publish-html-tutorial.html"&gt;org-publish&lt;/a&gt; for a simple, no-frills way to write &lt;code&gt;.org&lt;/code&gt; files and convert them to &lt;code&gt;.html&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;My &lt;code&gt;org-publish-project-alist&lt;/code&gt; now contains these entries:&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;(&amp;#34;lbolla.info&amp;#34;
 :components (&amp;#34;lbolla.info-html&amp;#34; &amp;#34;lbolla.info-static&amp;#34; &amp;#34;lbolla.info-cv&amp;#34;))
(&amp;#34;lbolla.info-static&amp;#34;
 :base-directory &amp;#34;~/src/lbolla.info/static/&amp;#34;
 :base-extension &amp;#34;png\\|jpg\\|\\|gif\\|gz\\|css&amp;#34;
 :publishing-directory &amp;#34;~/src/lbolla.info/html/&amp;#34;
 :recursive t
 :publishing-function org-publish-attachment)
(&amp;#34;lbolla.info-cv&amp;#34;
 :base-directory &amp;#34;~/src/lbolla.info/org/&amp;#34;
 :exclude &amp;#34;\\.*&amp;#34;
 :include (&amp;#34;cv.org&amp;#34;)
 :publishing-directory &amp;#34;~/src/lbolla.info/html/&amp;#34;
 :publishing-function org-latex-publish-to-pdf)
(&amp;#34;lbolla.info-html&amp;#34;
 :base-directory &amp;#34;~/src/lbolla.info/org/&amp;#34;
 :publishing-directory &amp;#34;~/src/lbolla.info/html/&amp;#34;
 :recursive t
 :section-numbers nil
 :auto-sitemap t
 :sitemap-format-entry lbolla.info/org-publish-sitemap-format-entry
 :sitemap-function lbolla.info/org-publish-sitemap-function
 :sitemap-sort-files anti-chronologically
 :sitemap-style tree
 :sitemap-title &amp;#34;Sitemap&amp;#34;
 :with-toc nil
 :html-doctype &amp;#34;html5&amp;#34;
 :html-head-include-default-style nil
 :html-head-include-scripts nil
 :html-link-home &amp;#34;&amp;lt;ignored&amp;gt;&amp;#34;
 :html-link-up &amp;#34;&amp;lt;ignored&amp;gt;&amp;#34;
 :html-home/up-format &amp;#34;&amp;lt;div id=\&amp;#34;org-div-home-and-up\&amp;#34;&amp;gt;&amp;lt;a accesskey=\&amp;#34;h\&amp;#34; href=\&amp;#34;/\&amp;#34;&amp;gt;Home&amp;lt;/a&amp;gt; | &amp;lt;a accesskey=\&amp;#34;a\&amp;#34; href=\&amp;#34;/articles\&amp;#34;&amp;gt;Articles&amp;lt;/a&amp;gt; | &amp;lt;a accesskey=\&amp;#34;c\&amp;#34; href=\&amp;#34;/cv\&amp;#34;&amp;gt;CV&amp;lt;/a&amp;gt; (&amp;lt;a href=\&amp;#34;/cv.pdf\&amp;#34;&amp;gt;pdf&amp;lt;/a&amp;gt;)&amp;lt;/div&amp;gt;&amp;#34;
 :html-preamble lbolla.info/html-preamble
 :html-postamble nil
 :html-head &amp;#34;&amp;lt;link rel=\&amp;#34;stylesheet\&amp;#34; href=\&amp;#34;./css/org.css\&amp;#34; type=\&amp;#34;text/css\&amp;#34;&amp;gt;&amp;#34;
 :html-head-extra &amp;#34;&amp;lt;link rel=\&amp;#34;stylesheet\&amp;#34; href=\&amp;#34;./css/extra.css\&amp;#34; type=\&amp;#34;text/css\&amp;#34;&amp;gt;&amp;#34;
 :publishing-function org-html-publish-to-html)
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Style is &lt;a href="http://gongzhitaao.org/orgcss/"&gt;this one&lt;/a&gt;: some CSS rules made for org-generated HTML files.&lt;/p&gt;</description></item><item><title>Elixir pipe operator in Python</title><link>https://lbolla-info.netlify.app/blog/elixir-pipe-operator-in-python/</link><pubDate>Wed, 25 May 2016 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/elixir-pipe-operator-in-python/</guid><description>&lt;p&gt;&lt;a href="http://elixir-lang.org"&gt;Elixir&lt;/a&gt; implements lots of nice ideas, one of which is its &lt;a href="http://elixir-lang.org/docs/stable/elixir/Kernel.html#%7C%3E/2"&gt;pipe operator&lt;/a&gt;. It allows you to write things like:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-elixir" data-lang="elixir"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;iex&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; [&lt;span style="color:#ae81ff"&gt;1&lt;/span&gt;, [&lt;span style="color:#ae81ff"&gt;2&lt;/span&gt;], &lt;span style="color:#ae81ff"&gt;3&lt;/span&gt;] &lt;span style="color:#f92672"&gt;|&amp;gt;&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;List&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;flatten()
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;[&lt;span style="color:#ae81ff"&gt;1&lt;/span&gt;, &lt;span style="color:#ae81ff"&gt;2&lt;/span&gt;, &lt;span style="color:#ae81ff"&gt;3&lt;/span&gt;]
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Or:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-elixir" data-lang="elixir"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;iex&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; inc &lt;span style="color:#f92672"&gt;=&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;fn&lt;/span&gt; x &lt;span style="color:#f92672"&gt;-&amp;gt;&lt;/span&gt; x &lt;span style="color:#f92672"&gt;+&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;1&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;end&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;iex&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; dec &lt;span style="color:#f92672"&gt;=&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;fn&lt;/span&gt; x &lt;span style="color:#f92672"&gt;-&amp;gt;&lt;/span&gt; x &lt;span style="color:#f92672"&gt;-&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;1&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;end&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;iex&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; square &lt;span style="color:#f92672"&gt;=&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;fn&lt;/span&gt; x &lt;span style="color:#f92672"&gt;-&amp;gt;&lt;/span&gt; x &lt;span style="color:#f92672"&gt;*&lt;/span&gt; x &lt;span style="color:#66d9ef"&gt;end&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;iex&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;5&lt;/span&gt; &lt;span style="color:#f92672"&gt;|&amp;gt;&lt;/span&gt; inc&lt;span style="color:#f92672"&gt;.&lt;/span&gt;() &lt;span style="color:#f92672"&gt;|&amp;gt;&lt;/span&gt; dec&lt;span style="color:#f92672"&gt;.&lt;/span&gt;() &lt;span style="color:#f92672"&gt;|&amp;gt;&lt;/span&gt; square&lt;span style="color:#f92672"&gt;.&lt;/span&gt;()
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#ae81ff"&gt;25&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Today, just for fun, I tried to implement something similar in Python. Here is the result:&lt;/p&gt;
&lt;script src="https://gist.github.com/lbolla/e7396c77e63b4c168cce27002f588494.js"&gt;&lt;/script&gt;
&lt;p&gt;So, you can write something like:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-python" data-lang="python"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;&amp;gt;&amp;gt;&amp;gt;&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;5&lt;/span&gt; &lt;span style="color:#f92672"&gt;|&lt;/span&gt;P&lt;span style="color:#f92672"&gt;|&lt;/span&gt; inc &lt;span style="color:#f92672"&gt;|&lt;/span&gt;P&lt;span style="color:#f92672"&gt;|&lt;/span&gt; dec &lt;span style="color:#f92672"&gt;|&lt;/span&gt;P&lt;span style="color:#f92672"&gt;|&lt;/span&gt; square
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#ae81ff"&gt;25&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Obviously, this is just a toy: it does not implement all the features available in the Elixir's one, but it was fun!&lt;/p&gt;</description></item><item><title>Comparison of blocking and non-blocking Python multiprocessing Queue</title><link>https://lbolla-info.netlify.app/blog/comparison-of-blocking-and-non-blocking-python-multiprocessing-queue/</link><pubDate>Mon, 25 Apr 2016 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/comparison-of-blocking-and-non-blocking-python-multiprocessing-queue/</guid><description>&lt;p&gt;Python's &lt;a href="https://docs.python.org/2/library/multiprocessing.html#multiprocessing.Queue"&gt;multiprocessing&lt;/a&gt; module offers a &lt;code&gt;Queue&lt;/code&gt; implementation. Surprisingly enough (for me at least), its performance varies greatly if used in a blocking or non-blocking fashion. In particular, the non-blocking way is about &lt;em&gt;ten times slower&lt;/em&gt; than the blocking one!&lt;/p&gt;
&lt;p&gt;Consider this code, which feeds a Queue and then drains it in a blocking and non-blocking way:&lt;/p&gt;
&lt;script src="https://gist.github.com/lbolla/92bad9f4320940ac2f762424ac840a12.js"&gt;&lt;/script&gt;
&lt;p&gt;Running it on my machine, with Python 2.7, gives me these results (Python 3.4 results are similar, but less dramatic):&lt;/p&gt;</description></item><item><title>Flycheck checker for Erlang dialyzer</title><link>https://lbolla-info.netlify.app/blog/flycheck-checker-for-erlang-dialyzer/</link><pubDate>Sat, 09 May 2015 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/flycheck-checker-for-erlang-dialyzer/</guid><description>&lt;p&gt;Emacs Erlang mode misses the definition of a &lt;a href="http://flycheck.readthedocs.org/en/latest/"&gt;flycheck&lt;/a&gt; checker using &lt;a href="http://www.erlang.org/doc/man/dialyzer.html"&gt;dialyzer&lt;/a&gt;. Just add these lines to your &lt;code&gt;.emacs&lt;/code&gt; to enable it:&lt;/p&gt;
&lt;script src="https://gist.github.com/lbolla/c989096bbc0ba31bb834.js"&gt;&lt;/script&gt;
&lt;p&gt;I prefer to use it &lt;em&gt;after&lt;/em&gt; the normal Erlang checker, so I define the following, too:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-lisp" data-lang="lisp"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;(flycheck-add-next-checker &lt;span style="color:#e6db74"&gt;&amp;#39;erlang&lt;/span&gt; &lt;span style="color:#e6db74"&gt;&amp;#39;erlang-dialyzer&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I also wrote another &lt;a href="https://lbolla-info.netlify.app/blog/flycheck-checker-for-flow/"&gt;Flycheck checker&lt;/a&gt; if you are interested.&lt;/p&gt;
&lt;p&gt;Enjoy!&lt;/p&gt;</description></item><item><title>EMpy 1.0 is out! Python3 compatible!</title><link>https://lbolla-info.netlify.app/blog/empy-1.0-is-out-python3-compatible/</link><pubDate>Sun, 26 Apr 2015 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/empy-1.0-is-out-python3-compatible/</guid><description>&lt;p&gt;After a long sleep, I resumed development on &lt;a href="https://lbolla-info.netlify.app/blog/empy/"&gt;Empy&lt;/a&gt;. The trigger was an appeal from Guido van Rossum at PyCon 2015 to package authors to support Python 3.&lt;/p&gt;
&lt;p&gt;There are no new features to &lt;a href="https://lbolla-info.netlify.app/blog/empy/"&gt;Empy&lt;/a&gt;, but I have:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;ported the code to Python 3, using the amazing &lt;a href="http://python-future.org/"&gt;future&lt;/a&gt; library: now, both Python 2 and 3 are supported;&lt;/li&gt;
&lt;li&gt;setup &lt;a href="https://travis-ci.org/lbolla/EMpy"&gt;Travis CI&lt;/a&gt; to run unittest on all supported Python versions;&lt;/li&gt;
&lt;li&gt;upgraded the dependencies to the latest available libraries;&lt;/li&gt;
&lt;li&gt;Pylint'd and pep8'd the code&lt;/li&gt;
&lt;li&gt;Renamed the package in PyPi to &lt;code&gt;ElectroMagneticPython&lt;/code&gt; to avoid name conflicts with &lt;a href="https://pypi.python.org/pypi/EmPy"&gt;EmPy&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;You can try it out by simply:&lt;/p&gt;</description></item><item><title>Flycheck checker for Flow</title><link>https://lbolla-info.netlify.app/blog/flycheck-checker-for-flow/</link><pubDate>Wed, 19 Nov 2014 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/flycheck-checker-for-flow/</guid><description>&lt;p&gt;&lt;a href="https://code.prod.facebook.com/posts/1505962329687926/flow-a-new-static-type-checker-for-javascript/"&gt;Yesterday&lt;/a&gt; Facebook open sourced &lt;a href="https://code.prod.facebook.com/posts/1505962329687926/flow-a-new-static-type-checker-for-javascript/"&gt;Flow&lt;/a&gt;, a static type checker for Javascript. If you use &lt;a href="http://www.gnu.org/software/emacs/"&gt;Emacs&lt;/a&gt;, you can use &lt;a href="http://flycheck.readthedocs.org/en/latest/"&gt;Flycheck&lt;/a&gt; to check your .js files on the fly using Flow.&lt;/p&gt;
&lt;p&gt;Here is the checker definition I use:&lt;/p&gt;
&lt;script src="https://gist.github.com/lbolla/476a030ff2fe06445918.js"&gt;&lt;/script&gt;
&lt;p&gt;I prefer to use Flow &lt;em&gt;after&lt;/em&gt; &lt;a href="https://developers.google.com/closure/utilities/docs/linter_howto"&gt;gjslint&lt;/a&gt;, so I define the following, too:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-lisp" data-lang="lisp"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;(flycheck-add-next-checker &lt;span style="color:#e6db74"&gt;&amp;#39;javascript-gjslint&lt;/span&gt; &lt;span style="color:#e6db74"&gt;&amp;#39;javascript-flow&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;I also wrote another &lt;a href="https://lbolla-info.netlify.app/blog/flycheck-checker-for-erlang-dialyzer/"&gt;Flycheck checker&lt;/a&gt; if you are interested.&lt;/p&gt;
&lt;p&gt;Enjoy!&lt;/p&gt;</description></item><item><title>Experiments in pickling</title><link>https://lbolla-info.netlify.app/blog/experiments-in-pickling/</link><pubDate>Wed, 14 May 2014 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/experiments-in-pickling/</guid><description>&lt;p&gt;&lt;a href="https://docs.python.org/2/library/pickle.html"&gt;&lt;code&gt;pickle&lt;/code&gt;&lt;/a&gt; is a standard library module to serialize and deserialize Python objects. Being written in pure Python, it's fairly slow, so the standard library provides a pure-C implementation, called &lt;a href="https://docs.python.org/2/library/pickle.html#module-cPickle"&gt;&lt;code&gt;cPickle&lt;/code&gt;&lt;/a&gt;, with the limitation that it cannot be &lt;a href="http://doughellmann.com/2007/06/24/pymotw-pickle-and-cpickle.html"&gt;subclassed&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;What's interesting about &lt;code&gt;cPickle&lt;/code&gt; are two little known settings that can speed up serialization quite substantially.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;a href="https://docs.python.org/2/library/pickle.html#pickle.HIGHEST_PROTOCOL"&gt;&lt;code&gt;cPickle.HIGHEST_PROTOCOL&lt;/code&gt;&lt;/a&gt; basically dumps a Python object using a binary protocol, rather than the default ASCII-based, more portable, protocol 0. If portability or backward compatibility are not an issue for you, you should use it: it's documented and probably here to stay.&lt;/p&gt;</description></item><item><title>Die zombie, die!</title><link>https://lbolla-info.netlify.app/blog/die-zombie-die/</link><pubDate>Thu, 23 Jan 2014 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/die-zombie-die/</guid><description>&lt;p&gt;The &lt;a href="https://docs.python.org/2/library/subprocess.html"&gt;&lt;code&gt;subprocess&lt;/code&gt;&lt;/a&gt; module in Python standard library allows you to spanw processes to do some tasks. The parent process should &lt;a href="https://docs.python.org/2/library/subprocess.html#subprocess.Popen.wait"&gt;&lt;code&gt;wait&lt;/code&gt;&lt;/a&gt; on its children processes in order get the return value of the process and &lt;a href="http://stackoverflow.com/questions/320232/ensuring-subprocesses-are-dead-on-exiting-python-program"&gt;avoid&lt;/a&gt; &lt;a href="http://stackoverflow.com/questions/2760652/how-to-kill-or-avoid-zombie-processes-with-subprocess-module"&gt;zombies&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Sometimes, though, processes are particularly hard to kill and even after a &lt;a href="https://docs.python.org/2/library/subprocess.html#subprocess.Popen.wait"&gt;&lt;code&gt;wait&lt;/code&gt;&lt;/a&gt;, a &lt;a href="https://docs.python.org/2/library/subprocess.html#subprocess.Popen.terminate"&gt;&lt;code&gt;terminate&lt;/code&gt;&lt;/a&gt; or a &lt;a href="https://docs.python.org/2/library/subprocess.html#subprocess.Popen.kill"&gt;&lt;code&gt;kill&lt;/code&gt;&lt;/a&gt; they refuse to die: they become &lt;a href="http://en.wikipedia.org/wiki/Zombie_process"&gt;zombies&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;In theory, Python should take care of reaping zombies for you once the zombie process gets garbage collected. In practice, it does not seem to work reliably and bigger weapons are needed.&lt;/p&gt;</description></item><item><title>Long running processes manager</title><link>https://lbolla-info.netlify.app/blog/long-running-processes-manager/</link><pubDate>Fri, 17 Jan 2014 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/long-running-processes-manager/</guid><description>&lt;p&gt;If you want to run multiple processes in Python, the nicest way, in my opinion, is to use &lt;a href="https://docs.python.org/3.4/library/concurrent.futures.html"&gt;concurrent.futures&lt;/a&gt; (there is a &lt;a href="https://pypi.python.org/pypi/futures"&gt;backport&lt;/a&gt; for Python 2.x, too).&lt;/p&gt;
&lt;p&gt;A problem that came up recently was to manage multiple long running processes, intended to run forever, from the same Python process. Using something like &lt;a href="http://supervisord.org/"&gt;supervisord&lt;/a&gt; wouldn't be ideal, because each individual application would have its own config file and deployment procedure.&lt;/p&gt;
&lt;p&gt;Instead, having just one &amp;quot;master&amp;quot; Python process to drive several other processes doing the job seemed the easiest solution to manage. The only caveat is that, being the processes managed long running, you want to restart them as soon as they die.&lt;/p&gt;</description></item><item><title>Overcoming Python GIL with Cython</title><link>https://lbolla-info.netlify.app/blog/overcoming-python-gil-with-cython/</link><pubDate>Mon, 23 Dec 2013 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/overcoming-python-gil-with-cython/</guid><description>&lt;p&gt;Everybody is aware of the infamous &lt;a href="https://wiki.python.org/moin/GlobalInterpreterLock"&gt;Python's GIL&lt;/a&gt;. In a nutshell, the GIL is a global variable that prevents multiple threads to be run concurrently by the interpreter. Under some occasions, for certain operations, the interpreter releases the GIL therefore in certain cases this is not a problem. For example, the GIL is released before doing I/O, so I/O bound threads tend to run concurrently. Another example is when doing system calls. Unfortunately, for CPU bound tasks that don't make any I/O or system calls, the GIL prevents different threads from running concurrently, even on multicore CPUs. The astonishing thing is that, in fact, not only different threads do not run concurrently, but they also run slower on multicore CPUs than on single core ones!&lt;/p&gt;</description></item><item><title>Connect to MSSQL from Python with ODBC and FreeTDS</title><link>https://lbolla-info.netlify.app/blog/connect-to-mssql-from-python-with-odbc-and-freetds/</link><pubDate>Thu, 29 Aug 2013 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/connect-to-mssql-from-python-with-odbc-and-freetds/</guid><description>&lt;p&gt;This is another of those posts that I wrote because I always forget how to do things&amp;hellip;&lt;/p&gt;
&lt;p&gt;This time, I don't want to forget how to connect from Python to MSSQL server anymore. In order to do it, you need the following system packages installed:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-shell" data-lang="shell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;$&amp;gt; sudo apt-get install unixodbc-dev tdsodbc sqsh
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;code&gt;sqsh&lt;/code&gt; installs all the required &lt;code&gt;freetds&lt;/code&gt;-related libraries; &lt;code&gt;tdsodbc&lt;/code&gt; is the &lt;a href="http://en.wikipedia.org/wiki/FreeTDS"&gt;FreeTDS&lt;/a&gt; driver for &lt;a href="http://en.wikipedia.org/wiki/ODBC"&gt;ODBC&lt;/a&gt; and &lt;code&gt;unixodbc-dev&lt;/code&gt; is needed to install &lt;a href="https://code.google.com/p/pyodbc/"&gt;&lt;code&gt;pyodbc&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Python and C with ctypes</title><link>https://lbolla-info.netlify.app/blog/python-and-c-with-ctypes/</link><pubDate>Wed, 28 Aug 2013 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/python-and-c-with-ctypes/</guid><description>&lt;p&gt;Calling C code from Python is very simple using &lt;a href="https://docs.python.org/2/library/ctypes.html"&gt;ctypes&lt;/a&gt;. Here is a very simple example to get you started and to serve as a reminder for me!&lt;/p&gt;
&lt;p&gt;Let's say you have this C file, defining 3 functions:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;foo&lt;/code&gt; which prints something to &lt;code&gt;stdout&lt;/code&gt;;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;bar&lt;/code&gt; which returns and &lt;code&gt;int&lt;/code&gt;;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;baz&lt;/code&gt; which takes a parameter and returns a value.&lt;/li&gt;
&lt;/ul&gt;
&lt;script src="https://gist.github.com/lbolla/6363780.js?file=go.c"&gt;&lt;/script&gt;
&lt;p&gt;First, you want to compile this C file into a shared object. Here is a &lt;code&gt;Makefile&lt;/code&gt; to do just this: simple type &lt;code&gt;make all&lt;/code&gt; and you're done.&lt;/p&gt;</description></item><item><title>Simple chat with Postgres LISTEN NOTIFY and Tornado IOLoop</title><link>https://lbolla-info.netlify.app/blog/simple-chat-with-postgres-listen-notify-and-tornado-ioloop/</link><pubDate>Thu, 21 Mar 2013 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/simple-chat-with-postgres-listen-notify-and-tornado-ioloop/</guid><description>&lt;p&gt;Postgres supports from version 8.4 a very interesting functionality: &lt;a href="http://www.postgresql.org/docs/9.2/static/sql-listen.html"&gt;LISTEN&lt;/a&gt;/&lt;a href="http://www.postgresql.org/docs/9.2/static/sql-notify.html"&gt;NOTIFY&lt;/a&gt; allows sending asynchronous messages to clients connected to the database.&lt;/p&gt;
&lt;p&gt;As in a normal &amp;quot;chat&amp;quot;, a client &amp;quot;subscribed&amp;quot; (&lt;code&gt;LISTEN&lt;/code&gt;) to a channel receives all the messages that other clients &amp;quot;sent&amp;quot; (&lt;code&gt;NOTIFY&lt;/code&gt;) on that channel.&lt;/p&gt;
&lt;p&gt;Since version 9.0, a notification message can have a payload string as long as 8000 bytes.&lt;/p&gt;
&lt;p&gt;In order to experiment with this feature, I've implemented a simple chat based on Tornado's &lt;a href="http://www.tornadoweb.org/en/stable/ioloop.html"&gt;IOLoop&lt;/a&gt;. Each client subscribes to a channel (or &amp;quot;room&amp;quot; in chat jargon) and listens to it &lt;a href="http://www.tornadoweb.org/en/stable/ioloop.html#tornado.ioloop.IOLoop.add_handler"&gt;adding a callback&lt;/a&gt; to react to a new notification. In the meantime, in another thread, the client is free to write and submit messages to the &amp;quot;room&amp;quot;. Here is a screenshot of the chat in action:&lt;/p&gt;</description></item><item><title>Use Postgres advanced types in Python</title><link>https://lbolla-info.netlify.app/blog/use-postgres-advanced-types-in-python/</link><pubDate>Wed, 06 Mar 2013 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/use-postgres-advanced-types-in-python/</guid><description>&lt;p&gt;Postgres has a lot of useful &lt;a href="http://www.postgresql.org/docs/9.2/static/datatype.html"&gt;builtin data types&lt;/a&gt;, but only some of them are mapped to Python types when accessing the DB using &lt;a href="http://initd.org/psycopg/"&gt;psycopg2&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Extending the support to other types is not straightforward, and involves the following steps:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Create a Python class to store the data, e.g. &lt;code&gt;class Point&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Write a function to convert a &lt;code&gt;Point&lt;/code&gt; to its SQL string representation, e.g. &lt;code&gt;adapt_point&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Write the inverse function to parse the SQL string representation of a &lt;code&gt;Point&lt;/code&gt; and return and instance of a &lt;code&gt;Point&lt;/code&gt;, e.g. &lt;code&gt;cast_point&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Finally bind all these functions and types, see &lt;code&gt;register_point_type&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The complete code is as follows, also available &lt;a href="https://gist.github.com/lbolla/5098907"&gt;as a gist&lt;/a&gt;:&lt;/p&gt;</description></item><item><title>Blocking tasks in Tornado</title><link>https://lbolla-info.netlify.app/blog/blocking-tasks-in-tornado/</link><pubDate>Tue, 22 Jan 2013 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/blocking-tasks-in-tornado/</guid><description>&lt;p&gt;Every now and then a &lt;a href="https://groups.google.com/d/topic/python-tornado/NVA5sTFIlPo/discussion"&gt;new discussion is raised on Tornado's mailling list about what is the best way to execute blocking tasks&lt;/a&gt;. It turns out that there are 3 feasible options, in order of increasing complexity:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;em&gt;Optimize blocking calls&lt;/em&gt;. Often, a slow DB query, or an overly complicate template are the blocking bottleneck. Rather than complicating the webserver, the first thing to try is to speed them up. This is sufficient 99% of the time.&lt;/li&gt;
&lt;li&gt;&lt;em&gt;Execute the slow task in a separate thread or process&lt;/em&gt;. This means off-loading the task to a different thread (or process) to the one running the &lt;code&gt;IOLoop&lt;/code&gt;, which is then free to accept other requests.&lt;/li&gt;
&lt;li&gt;&lt;em&gt;Use an asynchronous driver/library to run the task&lt;/em&gt;. For example, something like &lt;a href="http://www.gevent.org/"&gt;gevent&lt;/a&gt;, &lt;a href="http://emptysquare.net/blog/introducing-motor-an-asynchronous-mongodb-driver-for-python-and-tornado/"&gt;motor&lt;/a&gt; and the like.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;This blog post is about the second option, in particular using Python's &lt;a href="https://docs.python.org/3/library/concurrent.futures.html#module-concurrent.futures"&gt;&lt;code&gt;concurrent.futures&lt;/code&gt;&lt;/a&gt; package.&lt;/p&gt;</description></item><item><title>UnshareMe</title><link>https://lbolla-info.netlify.app/blog/unshareme/</link><pubDate>Wed, 12 Dec 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/unshareme/</guid><description>&lt;p&gt;Last my weekend project was to write something similar to &lt;a href="http://wehaslinks.com/"&gt;WeHasLinks&lt;/a&gt;. In fact, &lt;a href="http://wehaslinks.com/"&gt;WeHasLinks&lt;/a&gt; is a file sharing website, but I misread it as &amp;quot;We-Hash-Links&amp;quot; and the funny thing is that they &lt;em&gt;indeed&lt;/em&gt; hash their links (for obvious reasons&amp;hellip;). Anyway, &lt;a href="http://wehaslinks.com/"&gt;WeHasLinks&lt;/a&gt;'s links are hashed so that only the user who visited the page is allowed to them.&lt;/p&gt;
&lt;p&gt;I liked the idea very much, and I decided to implement it in &lt;a href="http://golang.org"&gt;go&lt;/a&gt;, as an exercise! You can find the code &lt;a href="https://github.com/lbolla/unshareme"&gt;on github&lt;/a&gt;. A demo is available at &lt;a href="http://unshareme.lbolla.info/"&gt;unshareme.lbolla.info&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Useful scripts - Watch</title><link>https://lbolla-info.netlify.app/blog/useful-scripts---watch/</link><pubDate>Fri, 30 Nov 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/useful-scripts---watch/</guid><description>&lt;p&gt;This is the fifth post of a series describing simple scripts that I wrote to ease my life as a programmer.&lt;/p&gt;
&lt;p&gt;They are &lt;a href="https://github.com/lbolla/cmd"&gt;available on github&lt;/a&gt;: fork &amp;amp; hack at will!&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/lbolla/cmd/blob/master/Watch"&gt;&lt;code&gt;Watch&lt;/code&gt;&lt;/a&gt; reacts to changes in a directory executing a command provided by the user. It can be used, for example, to monitor a directory and run some unittests as soon as files in it change. This is exactly how I am using &lt;code&gt;Watch&lt;/code&gt; in &lt;a href="http://acme.cat-v.org/"&gt;&lt;code&gt;acme&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Useful scripts - htmlind and xmlind</title><link>https://lbolla-info.netlify.app/blog/useful-scripts---htmlind-and-xmlind/</link><pubDate>Fri, 23 Nov 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/useful-scripts---htmlind-and-xmlind/</guid><description>&lt;p&gt;This is the forth post of a series describing simple scripts that I wrote to ease my life as a programmer.&lt;/p&gt;
&lt;p&gt;In this post I'll describe 2 simple scripts to indent nicely &lt;code&gt;HTML&lt;/code&gt; and &lt;code&gt;XML&lt;/code&gt; files. I use them primarily with &lt;a href="http://acme.cat-v.org/"&gt;&lt;code&gt;acme&lt;/code&gt;&lt;/a&gt;, to pipe selected text and get back nicely formatted output.&lt;/p&gt;
&lt;p&gt;Code is available here: &lt;a href="https://github.com/lbolla/cmd/blob/master/htmlind"&gt;&lt;code&gt;htmlind&lt;/code&gt;&lt;/a&gt; and &lt;a href="https://github.com/lbolla/cmd/blob/master/xmlind"&gt;&lt;code&gt;xmlind&lt;/code&gt;&lt;/a&gt;. Both programs are written in Python and make use of specialized libraries freely available online. In particular, &lt;code&gt;xmlind&lt;/code&gt; uses &lt;a href="https://docs.python.org/2/library/xml.dom.minidom.html"&gt;&lt;code&gt;xml.dom.minidom&lt;/code&gt;&lt;/a&gt;, included in Python's standard library, and &lt;code&gt;htmlind&lt;/code&gt; uses a modified version of &lt;a href="https://github.com/lbolla/cmd/blob/master/pylib/BeautifulSoup.py"&gt;&lt;code&gt;BeautifulSoup&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Useful scripts - csvfmt, xmlfmt, jsonfmt</title><link>https://lbolla-info.netlify.app/blog/useful-scripts---csvfmt-xmlfmt-jsonfmt/</link><pubDate>Fri, 16 Nov 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/useful-scripts---csvfmt-xmlfmt-jsonfmt/</guid><description>&lt;p&gt;This is the third post of a series describing simple scripts that I wrote to ease my life as a programmer.&lt;/p&gt;
&lt;p&gt;In this post, I'll describe 3 scripts to &amp;quot;pretty print&amp;quot; some common file types, to improve readability: &lt;a href="https://github.com/lbolla/cmd/blob/master/csvfmt"&gt;&lt;code&gt;csvfmt&lt;/code&gt;&lt;/a&gt;, &lt;a href="https://github.com/lbolla/cmd/blob/master/xmlfmt"&gt;&lt;code&gt;xmlfmt&lt;/code&gt;&lt;/a&gt; and &lt;a href="https://github.com/lbolla/cmd/blob/master/jsonfmt"&gt;&lt;code&gt;jsonfmt&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;a href="https://github.com/lbolla/cmd/blob/master/csvfmt"&gt;&lt;code&gt;csvfmt&lt;/code&gt;&lt;/a&gt; takes a &lt;code&gt;CSV&lt;/code&gt; (&amp;quot;Comma Separated Values&amp;quot;) file from &lt;code&gt;stdin&lt;/code&gt;, parses it and pretty print each record as a Python dictionary.&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-python" data-lang="python"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;#!/usr/bin/env python&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;import&lt;/span&gt; csv
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;import&lt;/span&gt; sys
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;import&lt;/span&gt; pprint
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;for&lt;/span&gt; row &lt;span style="color:#f92672"&gt;in&lt;/span&gt; csv&lt;span style="color:#f92672"&gt;.&lt;/span&gt;DictReader(sys&lt;span style="color:#f92672"&gt;.&lt;/span&gt;stdin):
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; pprint&lt;span style="color:#f92672"&gt;.&lt;/span&gt;pprint(row)
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Output looks like this:&lt;/p&gt;</description></item><item><title>Wordpress to markdown</title><link>https://lbolla-info.netlify.app/blog/wordpress-to-markdown/</link><pubDate>Mon, 12 Nov 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/wordpress-to-markdown/</guid><description>&lt;p&gt;Recently, I moved away from &lt;a href="http://wordpress.com/"&gt;Wordpress&lt;/a&gt;. I did it primarily because &lt;a href="http://john.onolan.org/ghost/"&gt;Wordpress is so much more than &lt;strong&gt;just&lt;/strong&gt; a blogging platform&lt;/a&gt; and what I needed was just a simple way of publishing posts with embedded code, links and images. Moreover, writing blogs using Wordpress's web editor is less than ideal&amp;hellip;&lt;/p&gt;
&lt;p&gt;The biggest problem to solve when moving away from Wordpress is how to not lose all your posts. Luckily, Wordpress allows you to &lt;a href="http://codex.wordpress.org/Tools_Export_Screen"&gt;export all your stuff in XML&lt;/a&gt;, but you also need a way to import them in whatever other blogging platform you are going to use.&lt;/p&gt;</description></item><item><title>Useful scripts - c+-c-</title><link>https://lbolla-info.netlify.app/blog/useful-scripts---c+-c-/</link><pubDate>Fri, 09 Nov 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/useful-scripts---c+-c-/</guid><description>&lt;p&gt;This is the second post of a series describing simple scripts that I wrote to ease my life as a programmer.&lt;/p&gt;
&lt;p&gt;They are &lt;a href="https://github.com/lbolla/cmd"&gt;available on github&lt;/a&gt;: fork &amp;amp; hack at will!&lt;/p&gt;
&lt;h2 id="cc-"&gt;c+/c-&lt;/h2&gt;
&lt;p&gt;In this post I'll describe a very simple script, &lt;a href="https://github.com/lbolla/cmd/blob/master/c%2B"&gt;&lt;code&gt;c+&lt;/code&gt;&lt;/a&gt;, and its counterpart &lt;a href="https://github.com/lbolla/cmd/blob/master/c-"&gt;&lt;code&gt;c-&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;code&gt;c+&lt;/code&gt; prepends every line of &lt;code&gt;stdin&lt;/code&gt; with &lt;code&gt;#&lt;/code&gt;. &lt;code&gt;c-&lt;/code&gt; strips &lt;code&gt;#&lt;/code&gt; from the beginning of each line of &lt;code&gt;stdin&lt;/code&gt;. I use these scripts to comment/uncomment lines in Python scripts when using &lt;a href="http://acme.cat-v.org/"&gt;&lt;code&gt;acme&lt;/code&gt;&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Useful scripts - a+-a-</title><link>https://lbolla-info.netlify.app/blog/useful-scripts---a+-a-/</link><pubDate>Fri, 02 Nov 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/useful-scripts---a+-a-/</guid><description>&lt;p&gt;This is the first post of a series describing simple scripts that I wrote to ease my life as a programmer.&lt;/p&gt;
&lt;p&gt;They are implemented in various languages (&lt;code&gt;python&lt;/code&gt;, &lt;code&gt;bash&lt;/code&gt;, &lt;code&gt;go&lt;/code&gt;) and thought to be used in &lt;code&gt;Linux&lt;/code&gt;. Some of them are &amp;quot;general purpose&amp;quot;, while others are specifically designed to interface other tools I use (for example, &lt;a href="http://acme.cat-v.org/"&gt;&lt;code&gt;acme&lt;/code&gt;&lt;/a&gt;.)&lt;/p&gt;
&lt;p&gt;All of them tend to have the following properties:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Input from &lt;code&gt;stdin&lt;/code&gt;, output to &lt;code&gt;stdout&lt;/code&gt;, errors to &lt;code&gt;stderr&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Return zero on success, non-zero on failure&lt;/li&gt;
&lt;li&gt;Do one thing only&lt;/li&gt;
&lt;li&gt;Not too much customizable&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;These properties allow the scripts to remain very simple, be composable and easy to remember.&lt;/p&gt;</description></item><item><title>URL Counter in GO</title><link>https://lbolla-info.netlify.app/blog/url-counter-in-go/</link><pubDate>Wed, 10 Oct 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/url-counter-in-go/</guid><description>&lt;p&gt;After having tinkered with #haskell for quite a bit, I decided that I needed some rest from theory and esoteric concepts, and a more pragmatic programming language to explore.&lt;/p&gt;
&lt;p&gt;I've spent the last few days refreshing my memories on &lt;a href="http://golang.org/"&gt;Go&lt;/a&gt;: I hadn&amp;rsquo;t touched it for almost 2 years and I must say that I find it changed: for the better.&lt;/p&gt;
&lt;p&gt;Here is a short tutorial on how to write a simple web application in Go, and publish it on &lt;a href="https://developers.google.com/appengine/"&gt;Google App Engine&lt;/a&gt;. The application is not a mere exercise, but scratches an itch I recently had: it counts how many times each of its handlers is hit. So, for example, visiting: &lt;a href="http://go-count-urls.appspot.com/hello"&gt;http://go-count-urls.appspot.com/hello&lt;/a&gt; returns how many times the &lt;code&gt;/hello&lt;/code&gt; handler has been visited. You can use it as a trivial real-time tracker.&lt;/p&gt;</description></item><item><title>Asynchronous programming with Tornado</title><link>https://lbolla-info.netlify.app/blog/asynchronous-programming-with-tornado/</link><pubDate>Wed, 03 Oct 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/asynchronous-programming-with-tornado/</guid><description>&lt;p&gt;Asynchronous programming can be tricky for beginners, therefore I think it's useful to iron some basic concepts to avoid common pitfalls. For an explanation about generic asynchronous programming, I recommend you one of the &lt;a href="http://en.wikipedia.org/wiki/Asynchrony"&gt;many&lt;/a&gt; &lt;a href="http://www.cs.brown.edu/courses/cs196-5/f12/handouts/async.pdf"&gt;resources&lt;/a&gt; &lt;a href="http://krondo.com/?page_id=1327"&gt;online&lt;/a&gt;. I will focus solely on asynchronous programming in &lt;a href="http://www.tornadoweb.org/documentation/index.html"&gt;Tornado&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;From Tornado's homepage:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;FriendFeed's web server is a relatively simple, non-blocking web server written in Python. The FriendFeed application is written using a web framework that looks a bit like web.py or Google's webapp, but with additional tools and optimizations to take advantage of the non-blocking web server and tools. Tornado is an open source version of this web server and some of the tools we use most often at FriendFeed. The framework is distinct from most mainstream web server frameworks (and certainly most Python frameworks) because it is non-blocking and reasonably fast. Because it is non-blocking and uses epoll or kqueue, it can handle thousands of simultaneous standing connections, which means the framework is ideal for real-time web services. We built the web server specifically to handle FriendFeed's real-time features every active user of FriendFeed maintains an open connection to the FriendFeed servers. (For more information on scaling servers to support thousands of clients, see The C10K problem.)&lt;/p&gt;</description></item><item><title>Tornado vs. Warp vs. Yesod</title><link>https://lbolla-info.netlify.app/blog/tornado-vs.-warp-vs.-yesod/</link><pubDate>Sun, 02 Sep 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/tornado-vs.-warp-vs.-yesod/</guid><description>&lt;p&gt;Today I tried to benchmark 3 web servers that I've used recently:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href="http://www.tornadoweb.org/"&gt;Tornado&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://hackage.haskell.org/package/warp/"&gt;Warp&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.yesodweb.com/"&gt;Yesod&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;In fact, these are only *2* web servers, because &lt;code&gt;Yesod&lt;/code&gt; runs on top of Warp and it's a fully fledged web framework, rather than a web server: but this was also the intent of the benchmark, i.e. to measure how slower all its goodies made Yesod with respect to Warp.&lt;/p&gt;
&lt;p&gt;Tornado and Warp are obviously very different web servers (async vs. threaded, interpreted vs. compiled, etc.) but, &lt;a href="http://ziutek.github.com/web_bench/"&gt;who cares&lt;/a&gt;?&lt;/p&gt;</description></item><item><title>EMpy has moved!</title><link>https://lbolla-info.netlify.app/blog/empy-has-moved/</link><pubDate>Mon, 25 Jun 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/empy-has-moved/</guid><description>&lt;p&gt;&lt;a href="https://lbolla-info.netlify.app/blog/empy/"&gt;Empy&lt;/a&gt; has &lt;a href="http://lbolla.github.com/EMpy/"&gt;moved to Github&lt;/a&gt;!&lt;/p&gt;</description></item><item><title>Pipelines in Python</title><link>https://lbolla-info.netlify.app/blog/pipelines-in-python/</link><pubDate>Fri, 20 Apr 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/pipelines-in-python/</guid><description>&lt;p&gt;Generators (&lt;a href="http://www.python.org/dev/peps/pep-0255/"&gt;PEP 255 &amp;quot;Simple Generators&amp;quot;&lt;/a&gt;) and Coroutines (&lt;a href="http://www.python.org/dev/peps/pep-0342/"&gt;PEP 342 &amp;quot;Coroutines via Enhanced Generators&amp;quot;&lt;/a&gt;) are the cleanest way I've come across so far to implement the concept of a &amp;quot;pipeline&amp;quot; in Python.&lt;/p&gt;
&lt;h2 id="first-approximation"&gt;First approximation&lt;/h2&gt;
&lt;p&gt;A pipeline is made of:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;a &lt;em&gt;Producer&lt;/em&gt;, that generates data;&lt;/li&gt;
&lt;li&gt;many /Stage/s, that receive data from the previous stage and send it to the next;&lt;/li&gt;
&lt;li&gt;a &lt;em&gt;Consumer&lt;/em&gt;, that receives data from the last stage.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The producer is a coroutine that only /send/s data, generated internally from some initial state. /Stage/s are coroutines that both receive and send messages. The &lt;em&gt;consumer&lt;/em&gt; only receives data. Chaining is done in function &lt;em&gt;pipeline&lt;/em&gt;: each argument but the last is instantiated with an instance of the next stage. The full pipeline is &lt;em&gt;started&lt;/em&gt; by issuing a &lt;em&gt;next&lt;/em&gt; (or &lt;em&gt;send(None)&lt;/em&gt;) to the &lt;em&gt;Producer&lt;/em&gt;.&lt;/p&gt;</description></item><item><title>hsenv</title><link>https://lbolla-info.netlify.app/blog/hsenv/</link><pubDate>Thu, 29 Mar 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/hsenv/</guid><description>&lt;p&gt;If you have never used &lt;a href="https://github.com/Paczesiowa/hsenv"&gt;hsenv&lt;/a&gt; before, you should. It's basically the Haskell's equivalent of Python's &lt;a href="http://pypi.python.org/pypi/virtualenv"&gt;virtualenv&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;You can find a &lt;a href="https://github.com/lbolla/hsenv"&gt;tweaked version of hsenv here&lt;/a&gt;: I've relaxed some requirements in order to make it install on newer GHC releases.&lt;/p&gt;
&lt;p&gt;Finally, if when using you hit this error:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-shell" data-lang="shell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;$ hsenv Creating Virtual Haskell directory structure
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;Installing GHC Initializing GHC Package database at /home/lollo/work/Unique/.hsenv/ghc_pkg_db
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;Copying necessary packages from original GHC package database
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;hsenv: fd:9: hGetContents: invalid argument &lt;span style="color:#f92672"&gt;(&lt;/span&gt;invalid byte sequence&lt;span style="color:#f92672"&gt;)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;hsenv: thread blocked indefinitely in an MVar operation
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Then, you have a problem with your locale. Follow the steps &lt;a href="https://wiki.archlinux.org/index.php/Locale#Enabling_necessary_locales"&gt;here&lt;/a&gt;, and retry.&lt;/p&gt;</description></item><item><title>Sudoku solver in Haskell</title><link>https://lbolla-info.netlify.app/blog/sudoku-solver-in-haskell/</link><pubDate>Mon, 27 Feb 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/sudoku-solver-in-haskell/</guid><description>&lt;p&gt;Recently, I've been challenged to write a &lt;a href="http://en.wikipedia.org/wiki/Sudoku"&gt;Sudoku&lt;/a&gt; solver. Not knowing the rules and with only 30 minutes, I needed some help&amp;hellip;&lt;/p&gt;
&lt;p&gt;So, in case someone asks me again, I've implemented the same algorithm in Haskell.&lt;/p&gt;
&lt;script src="https://gist.github.com/1925630.js"&gt; &lt;/script&gt;
&lt;p&gt;I know that &lt;a href="http://www.haskell.org/haskellwiki/Sudoku"&gt;there are already a lot of other solutions&lt;/a&gt;, but, hey, it was fun!&lt;/p&gt;</description></item><item><title>HTTPS authentication in nginx</title><link>https://lbolla-info.netlify.app/blog/https-authentication-in-nginx/</link><pubDate>Mon, 20 Feb 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/https-authentication-in-nginx/</guid><description>&lt;p&gt;In order not to forget again how to setup &lt;a href="http://en.wikipedia.org/wiki/Basic_access_authentication"&gt;http authentication&lt;/a&gt; in &lt;a href="http://nginx.org/"&gt;nginx&lt;/a&gt; here is a reminder.&lt;/p&gt;
&lt;p&gt;For &lt;code&gt;HTTPS&lt;/code&gt; follow &lt;a href="http://dracoblue.net/dev/https-nginx-with-self-signed-ssl-certificate/188/"&gt;these steps&lt;/a&gt;:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-shell" data-lang="shell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;$ sudo -s
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;# cd /etc/nginx&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;# openssl req -new -x509 -nodes -out server.crt -keyout server.key&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;and add these lines to your &lt;code&gt;server&lt;/code&gt; instance:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-nginx" data-lang="nginx"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;server&lt;/span&gt; {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#f92672"&gt;listen&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;443&lt;/span&gt;;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#f92672"&gt;ssl&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;on&lt;/span&gt;;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#f92672"&gt;ssl_certificate&lt;/span&gt; &lt;span style="color:#e6db74"&gt;/etc/nginx/server.crt&lt;/span&gt;;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#f92672"&gt;ssl_certificate_key&lt;/span&gt; &lt;span style="color:#e6db74"&gt;/etc/nginx/server.key&lt;/span&gt;;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;...&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;To setup basic authentication, add these lines to the same file:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-nginx" data-lang="nginx"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;location&lt;/span&gt; &lt;span style="color:#e6db74"&gt;/&lt;/span&gt; {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#f92672"&gt;auth_basic&lt;/span&gt; &lt;span style="color:#e6db74"&gt;&amp;#34;Restricted&amp;#34;&lt;/span&gt;;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#f92672"&gt;auth_basic_user_file&lt;/span&gt; &lt;span style="color:#e6db74"&gt;/etc/nginx/htpasswd&lt;/span&gt;;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#75715e"&gt;# you might also want to deny access based on IP here
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#75715e"&gt;#allow &amp;lt;ip-address&amp;gt;;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#75715e"&gt;#deny all;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;...&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Finally, to generate &lt;code&gt;/etc/nginx/htpasswd&lt;/code&gt;, use this one-liner:&lt;/p&gt;</description></item><item><title>ulint, Universal Lint</title><link>https://lbolla-info.netlify.app/blog/ulint-universal-lint/</link><pubDate>Thu, 05 Jan 2012 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/ulint-universal-lint/</guid><description>&lt;p&gt;I've been using so many code static checkers lately, that I decided to write a wrapper around the ones I use the most. I called it: &lt;a href="https://github.com/lbolla/ulint"&gt;Universal Lint&lt;/a&gt;, &lt;a href="https://github.com/lbolla/ulint"&gt;ulint&lt;/a&gt; for short.&lt;/p&gt;
&lt;p&gt;At the moment, Python, Javascript and Haskell files are supported, but adding new linters/extension is trivial.&lt;/p&gt;
&lt;p&gt;Download it and use it!&lt;/p&gt;</description></item><item><title>HSGrep benchmarking</title><link>https://lbolla-info.netlify.app/blog/hsgrep-benchmarking/</link><pubDate>Wed, 30 Nov 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/hsgrep-benchmarking/</guid><description>&lt;p&gt;Few days ago, &lt;a href="https://lbolla-info.netlify.app/blog/hsgrep-sorted-grep-in-haskell/"&gt;I rewrote &lt;code&gt;sgrep&lt;/code&gt; in Haskell&lt;/a&gt;. I was curious to know how it compares to &lt;a href="http://en.wikipedia.org/wiki/Grep.org"&gt;&lt;code&gt;grep&lt;/code&gt;&lt;/a&gt; in term of execution speed. In particular, I was interested to verify that &lt;code&gt;hsgrep&lt;/code&gt; scales as &lt;code&gt;O(log n)&lt;/code&gt;, instead of &lt;code&gt;O(n)&lt;/code&gt;, with &lt;code&gt;n&lt;/code&gt; being the size of the file analyzed.&lt;/p&gt;
&lt;p&gt;First of all, in order to have similar performance to &lt;code&gt;grep&lt;/code&gt;, I had to convert my original program to use &lt;a href="http://hackage.haskell.org/packages/archive/bytestring/latest/doc/html/Data-ByteString.html"&gt;Haskell's bytestrings&lt;/a&gt;. &lt;a href="https://github.com/lbolla/HSGrep/tree/bytestring"&gt;You can find the code here&lt;/a&gt;. Testing files are generated with &lt;a href="https://github.com/lbolla/HSGrep/blob/bytestring/data/gendata.hs"&gt;this script&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>HSGrep Sorted grep in Haskell</title><link>https://lbolla-info.netlify.app/blog/hsgrep-sorted-grep-in-haskell/</link><pubDate>Sun, 27 Nov 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/hsgrep-sorted-grep-in-haskell/</guid><description>&lt;p&gt;As an exercise to learn &lt;a href="http://haskell.org/haskellwiki/Haskell"&gt;Haskell&lt;/a&gt;, I wrote a specialized &lt;code&gt;grep&lt;/code&gt; to work on sorted files. It uses &lt;a href="http://en.wikipedia.org/wiki/Binary_search_algorithm"&gt;binary search&lt;/a&gt; to scan a text file and print all the (consecutive) lines that start with a user defined string.&lt;/p&gt;
&lt;p&gt;My program is a rewrite of &lt;a href="http://sourceforge.net/projects/sgrep/"&gt;&lt;code&gt;sgrep&lt;/code&gt;&lt;/a&gt; in &lt;a href="http://haskell.org/haskellwiki/Haskell"&gt;Haskell&lt;/a&gt;: I called it &lt;a href="https://github.com/lbolla/HSGrep"&gt;HSGrep&lt;/a&gt;. Code is available on &lt;a href="https://github.com/lbolla/HSGrep"&gt;github&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Thanks a lot for &lt;a href="http://codereview.stackexchange.com/q/6318/8638"&gt;all your useful suggestions&lt;/a&gt;! As soon as possible, I'll post some benchmarking &lt;a href="https://lbolla-info.netlify.app/blog/hsgrep-benchmarking/"&gt;here&lt;/a&gt;. (EDIT: &lt;a href="https://lbolla-info.netlify.app/blog/hsgrep-benchmarking/"&gt;benchmarks now available!&lt;/a&gt;)&lt;/p&gt;
&lt;p&gt;After downloading the &lt;a href="https://github.com/lbolla/HSGrep"&gt;source code&lt;/a&gt;, build install and run it with:&lt;/p&gt;</description></item><item><title>git pre-commit hook for Python and Javascript</title><link>https://lbolla-info.netlify.app/blog/git-pre-commit-hook-for-python-and-javascript/</link><pubDate>Thu, 17 Nov 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/git-pre-commit-hook-for-python-and-javascript/</guid><description>&lt;p&gt;Following a &lt;a href="http://news.ycombinator.com/item?id=3244475"&gt;recent discussion on HN&lt;/a&gt;, I decided to share my own &lt;a href="http://book.git-scm.com/5_git_hooks.html"&gt;git pre-commit hook&lt;/a&gt;.&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-python" data-lang="python"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;#!/usr/bin/python&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;import&lt;/span&gt; os
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;import&lt;/span&gt; sys
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;import&lt;/span&gt; re
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;import&lt;/span&gt; subprocess
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;devnull &lt;span style="color:#f92672"&gt;=&lt;/span&gt; open(os&lt;span style="color:#f92672"&gt;.&lt;/span&gt;devnull, &lt;span style="color:#e6db74"&gt;&amp;#39;w&amp;#39;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;def&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;call&lt;/span&gt;(cmd):
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; p &lt;span style="color:#f92672"&gt;=&lt;/span&gt; subprocess&lt;span style="color:#f92672"&gt;.&lt;/span&gt;Popen(cmd&lt;span style="color:#f92672"&gt;.&lt;/span&gt;split(),
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; stdout&lt;span style="color:#f92672"&gt;=&lt;/span&gt;subprocess&lt;span style="color:#f92672"&gt;.&lt;/span&gt;PIPE,
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; stderr&lt;span style="color:#f92672"&gt;=&lt;/span&gt;subprocess&lt;span style="color:#f92672"&gt;.&lt;/span&gt;PIPE)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; out, err &lt;span style="color:#f92672"&gt;=&lt;/span&gt; p&lt;span style="color:#f92672"&gt;.&lt;/span&gt;communicate()
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;return&lt;/span&gt; out&lt;span style="color:#f92672"&gt;.&lt;/span&gt;decode(&lt;span style="color:#e6db74"&gt;&amp;#39;utf-8&amp;#39;&lt;/span&gt;), err&lt;span style="color:#f92672"&gt;.&lt;/span&gt;decode(&lt;span style="color:#e6db74"&gt;&amp;#39;utf-8&amp;#39;&lt;/span&gt;), p&lt;span style="color:#f92672"&gt;.&lt;/span&gt;returncode
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;def&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;execute&lt;/span&gt;(cmd, silent&lt;span style="color:#f92672"&gt;=&lt;/span&gt;&lt;span style="color:#66d9ef"&gt;False&lt;/span&gt;):
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;if&lt;/span&gt; silent:
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; params &lt;span style="color:#f92672"&gt;=&lt;/span&gt; {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#e6db74"&gt;&amp;#39;stdout&amp;#39;&lt;/span&gt;: devnull,
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#e6db74"&gt;&amp;#39;stderr&amp;#39;&lt;/span&gt;: devnull,
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; }
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;else&lt;/span&gt;:
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; params &lt;span style="color:#f92672"&gt;=&lt;/span&gt; {}
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; retcode &lt;span style="color:#f92672"&gt;=&lt;/span&gt; subprocess&lt;span style="color:#f92672"&gt;.&lt;/span&gt;call(cmd&lt;span style="color:#f92672"&gt;.&lt;/span&gt;split(), &lt;span style="color:#f92672"&gt;**&lt;/span&gt;params)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;return&lt;/span&gt; retcode
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;def&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;exists&lt;/span&gt;(cmd):
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;return&lt;/span&gt; execute(&lt;span style="color:#e6db74"&gt;&amp;#39;which &lt;/span&gt;&lt;span style="color:#e6db74"&gt;%s&lt;/span&gt;&lt;span style="color:#e6db74"&gt;&amp;#39;&lt;/span&gt; &lt;span style="color:#f92672"&gt;%&lt;/span&gt; cmd, silent&lt;span style="color:#f92672"&gt;=&lt;/span&gt;&lt;span style="color:#66d9ef"&gt;True&lt;/span&gt;) &lt;span style="color:#f92672"&gt;==&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;0&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;def&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;get_modified&lt;/span&gt;(ext):
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; modified &lt;span style="color:#f92672"&gt;=&lt;/span&gt; re&lt;span style="color:#f92672"&gt;.&lt;/span&gt;compile(&lt;span style="color:#e6db74"&gt;&amp;#39;^(?:M|A).(?P&amp;lt;name&amp;gt;.*\.&lt;/span&gt;&lt;span style="color:#e6db74"&gt;%s&lt;/span&gt;&lt;span style="color:#e6db74"&gt;)&amp;#39;&lt;/span&gt; &lt;span style="color:#f92672"&gt;%&lt;/span&gt; ext)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; out, _, _ &lt;span style="color:#f92672"&gt;=&lt;/span&gt; call(&lt;span style="color:#e6db74"&gt;&amp;#39;git status --porcelain&amp;#39;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; modifieds &lt;span style="color:#f92672"&gt;=&lt;/span&gt; []
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;for&lt;/span&gt; line &lt;span style="color:#f92672"&gt;in&lt;/span&gt; out&lt;span style="color:#f92672"&gt;.&lt;/span&gt;splitlines():
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;match&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; modified&lt;span style="color:#f92672"&gt;.&lt;/span&gt;&lt;span style="color:#66d9ef"&gt;match&lt;/span&gt;(line&lt;span style="color:#f92672"&gt;.&lt;/span&gt;strip())
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;if&lt;/span&gt; (&lt;span style="color:#66d9ef"&gt;match&lt;/span&gt;):
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; modifieds&lt;span style="color:#f92672"&gt;.&lt;/span&gt;append(&lt;span style="color:#66d9ef"&gt;match&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;group(&lt;span style="color:#e6db74"&gt;&amp;#39;name&amp;#39;&lt;/span&gt;))
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;return&lt;/span&gt; modifieds
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;It's a work-in-progress, so you can find the &lt;a href="https://github.com/lbolla/dotfiles/blob/master/githooks/pre-commit"&gt;most updated version here&lt;/a&gt;. To use it, just drop it in your &lt;code&gt;.git/hooks&lt;/code&gt; directory. At every &lt;code&gt;git commit&lt;/code&gt;, it will run &lt;code&gt;[pep8][4]&lt;/code&gt; and &lt;code&gt;[pyflakes][5]&lt;/code&gt; on &lt;code&gt;.py&lt;/code&gt; files, and &lt;code&gt;[gjslint][6]&lt;/code&gt; on &lt;code&gt;.js&lt;/code&gt; files.&lt;/p&gt;</description></item><item><title>Haskell and VIM</title><link>https://lbolla-info.netlify.app/blog/haskell-and-vim/</link><pubDate>Sat, 15 Oct 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/haskell-and-vim/</guid><description>&lt;p&gt;I had to tinker quite a bit before finding a decent configuration for vim to edit Haskell files. Here are the packages and config files I use:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="http://projects.haskell.org/haskellmode-vim/"&gt;Haskell mode&lt;/a&gt;: interaction with &lt;a href="http://www.haskell.org/haddock/"&gt;Haddock&lt;/a&gt;, compiler integration, and other general settings.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.vim.org/scripts/script.php?script_id=1968"&gt;Indentation&lt;/a&gt;: proper source code indentation.&lt;/li&gt;
&lt;li&gt;More configs to enforce &lt;a href="http://urchin.earth.li/~ian/style/haskell.html"&gt;good style&lt;/a&gt; (no tabs, tabstops, etc.):&lt;/li&gt;
&lt;/ul&gt;
&lt;script src="https://gist.github.com/1289349.js"&gt; &lt;/script&gt;
&lt;p&gt;You can also have them &lt;a href="./assets/haskell-vim-config.tar.gz"&gt;bundled all together&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>They broke delicious</title><link>https://lbolla-info.netlify.app/blog/they-broke-delicious/</link><pubDate>Fri, 30 Sep 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/they-broke-delicious/</guid><description>&lt;p&gt;The new redesign of &lt;a href="http://www.delicious.com"&gt;delicious.com&lt;/a&gt; broke so many things, that I thought I had to take notes:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="http://www.delicious.com/help/bookmarklets"&gt;bookmarklet&lt;/a&gt; in Chrome can't be drag-n-dropped to the toolbar. Its Javascript code is also hard to copy and paste to create the bookmarklet &amp;quot;manually&amp;quot;.&lt;/li&gt;
&lt;li&gt;install links for the &lt;a href="http://www.delicious.com/help/quicktour/chrome"&gt;chrome&lt;/a&gt; and &lt;a href="http://www.delicious.com/help/quicktour/firefox"&gt;Firefox&lt;/a&gt; extensions redirect to &lt;a href="http://www.delicious.com/help/installff"&gt;empty pages&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.delicious.com/help/tools"&gt;documentation for developer&lt;/a&gt; is coming soon (!)&lt;/li&gt;
&lt;li&gt;the &lt;a href="http://www.delicious.com/"&gt;top-right menu&lt;/a&gt; with the logged-in username and stuff is the most horrible I've ever seen: it changes its width on hover, the corners look interrupted (in Chrome, at least &amp;ndash; I'm not bothered trying with other browsers)&lt;/li&gt;
&lt;li&gt;what the hell are &lt;a href="http://www.delicious.com/stacks/lbolla"&gt;stacks&lt;/a&gt;? Grouping can be done with tags, already, and I don't want that much space in the page taken by a &amp;quot;social&amp;quot; feature! Who needs it?&lt;/li&gt;
&lt;li&gt;the list of links in the main personal page only shows 8 links on my screen&amp;hellip; 8 links?! There's way too much padding, too whitespaces, too much to scroll&amp;hellip; It's a bookmarking services, it should show you bookmarks in the most friendly way!&lt;/li&gt;
&lt;li&gt;image: why should I use an image for myself? And if I don't use one, &lt;a href="http://www.delicious.com/static/img/profile/keyboardcat.png"&gt;I got assigned one by default&lt;/a&gt;&amp;hellip; Please&amp;hellip;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I'll add more to the list in the future.&lt;/p&gt;</description></item><item><title>HTTP client in Haskell</title><link>https://lbolla-info.netlify.app/blog/http-client-in-haskell/</link><pubDate>Mon, 26 Sep 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/http-client-in-haskell/</guid><description>&lt;p&gt;To try to make sense of &lt;a href="http://learnyouahaskell.com/functors-applicative-functors-and-monoids"&gt;this&lt;/a&gt;, I decided to write a &amp;quot;simple&amp;quot; http client in Haskell in as many styles as I could think of:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-haskell" data-lang="haskell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;import&lt;/span&gt; Network.HTTP
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;import&lt;/span&gt; Control.Applicative
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#a6e22e"&gt;url&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; &lt;span style="color:#e6db74"&gt;&amp;#34;http://www.haskell.org/haskellwiki/Haskell&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;-- Imperative style&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#a6e22e"&gt;fetch_1&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;do&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; rsp &lt;span style="color:#f92672"&gt;&amp;lt;-&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;Network&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;&lt;span style="color:#66d9ef"&gt;HTTP&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;simpleHTTP (getRequest url)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; body &lt;span style="color:#f92672"&gt;&amp;lt;-&lt;/span&gt; getResponseBody rsp
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; return (take &lt;span style="color:#ae81ff"&gt;1000&lt;/span&gt; body)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;-- With Functors&amp;#39; fmap&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#a6e22e"&gt;fetch_2&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;do&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; rsp &lt;span style="color:#f92672"&gt;&amp;lt;-&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;Network&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;&lt;span style="color:#66d9ef"&gt;HTTP&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;simpleHTTP (getRequest url)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; fmap (take &lt;span style="color:#ae81ff"&gt;1000&lt;/span&gt;) (getResponseBody rsp)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;-- With Applicative&amp;#39;s &amp;gt;&amp;gt;=&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#a6e22e"&gt;fetch_3&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; fmap (take &lt;span style="color:#ae81ff"&gt;1000&lt;/span&gt;) (&lt;span style="color:#66d9ef"&gt;Network&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;&lt;span style="color:#66d9ef"&gt;HTTP&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;simpleHTTP (getRequest url) &lt;span style="color:#f92672"&gt;&amp;gt;&amp;gt;=&lt;/span&gt; getResponseBody)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;-- &amp;#34;fmap f x&amp;#34; is the same as &amp;#34;pure f &amp;lt;*&amp;gt; x&amp;#34; (Applicative&amp;#39;s law)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#a6e22e"&gt;fetch_4&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; pure (take &lt;span style="color:#ae81ff"&gt;1000&lt;/span&gt;) &lt;span style="color:#f92672"&gt;&amp;lt;*&amp;gt;&lt;/span&gt; (&lt;span style="color:#66d9ef"&gt;Network&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;&lt;span style="color:#66d9ef"&gt;HTTP&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;simpleHTTP (getRequest url) &lt;span style="color:#f92672"&gt;&amp;gt;&amp;gt;=&lt;/span&gt; getResponseBody)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;-- &amp;#34;pure f &amp;lt;*&amp;gt; x&amp;#34; is the same as &amp;#34;f &amp;lt;$&amp;gt; x&amp;#34;&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#a6e22e"&gt;fetch_5&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; (take &lt;span style="color:#ae81ff"&gt;1000&lt;/span&gt;) &lt;span style="color:#f92672"&gt;&amp;lt;$&amp;gt;&lt;/span&gt; (&lt;span style="color:#66d9ef"&gt;Network&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;&lt;span style="color:#66d9ef"&gt;HTTP&lt;/span&gt;&lt;span style="color:#f92672"&gt;.&lt;/span&gt;simpleHTTP (getRequest url) &lt;span style="color:#f92672"&gt;&amp;gt;&amp;gt;=&lt;/span&gt; getResponseBody)
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;It's a long time since I found so many new concepts while studying a new programming language&amp;hellip;&lt;/p&gt;</description></item><item><title>pylint.vim</title><link>https://lbolla-info.netlify.app/blog/pylint.vim/</link><pubDate>Thu, 25 Aug 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/pylint.vim/</guid><description>&lt;p&gt;&lt;code&gt;vim&lt;/code&gt; + Python + &lt;a href="http://www.logilab.org/857"&gt;&lt;code&gt;pylint&lt;/code&gt;&lt;/a&gt; is a powerful combination, especially when using this &lt;a href="http://www.vim.org/scripts/script.php?script_id=891"&gt;&lt;code&gt;vim&lt;/code&gt; plugin&lt;/a&gt;. Unfortunately, the script stopped working after a &lt;code&gt;pylint&lt;/code&gt; upgrade:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-shell" data-lang="shell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;$ pylint --version
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;pylint 0.24.0,
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;astng 0.22.0, common 0.56.0
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;Python 2.7.2 &lt;span style="color:#f92672"&gt;(&lt;/span&gt;default, Jun &lt;span style="color:#ae81ff"&gt;29&lt;/span&gt; 2011, 11:10:00&lt;span style="color:#f92672"&gt;)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;[&lt;/span&gt;GCC 4.6.1&lt;span style="color:#f92672"&gt;]&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;You can download the &lt;a href="https://gist.github.com/1170413"&gt;fixed version here&lt;/a&gt;!&lt;/p&gt;
&lt;p&gt;If interested, the patch looks like this:&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code class="language-vimscript" data-lang="vimscript"&gt;diff pylint.vim.orig pylint.vim
69c69
&amp;lt; CompilerSet makeprg=(echo\ &amp;#39;[%]&amp;#39;;\ pylint\ -r\ y\ %)
---
&amp;gt; CompilerSet makeprg=(echo\ &amp;#39;[%]&amp;#39;;\ pylint\ -r\ y\ --output-format=parseable\
&amp;gt; %)
74c74
&amp;lt; CompilerSet efm=%+P[%f],%t:\ %#%l:%m,%Z,%+IYour\ code%m,%Z,%-G%.%#
---
&amp;gt; CompilerSet efm=%f:%l:\ [%t]%m,%f:%l:%m
&lt;/code&gt;&lt;/pre&gt;</description></item><item><title>MD5 vs SHA1 in Python</title><link>https://lbolla-info.netlify.app/blog/md5-vs-sha1-in-python/</link><pubDate>Wed, 24 Aug 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/md5-vs-sha1-in-python/</guid><description>&lt;p&gt;If you are interested to know if the &lt;a href="http://omnifarious.livejournal.com/363945.html"&gt;myth about &lt;code&gt;MD5&lt;/code&gt; being faster than &lt;code&gt;SHA1&lt;/code&gt;&lt;/a&gt; holds for Python, here is the result I got on my box:&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code class="language-ipython" data-lang="ipython"&gt;In [1]: import hashlib
In [2]: %timeit hashlib.md5(&amp;#39;text text text&amp;#39;).hexdigest()
1000000 loops, best of 3: 1.29 us per loop
In [3]: %timeit hashlib.sha1(&amp;#39;text text text&amp;#39;).hexdigest()
1000000 loops, best of 3: 1.4 us per loop
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Result is: &lt;code&gt;MD5&lt;/code&gt; is faster, but only just, in Python 2.7.2. Considering that &lt;a href="http://en.wikipedia.org/wiki/%60MD5%60"&gt;&lt;code&gt;MD5&lt;/code&gt; is broken&lt;/a&gt;, I think I'll use &lt;code&gt;SHA1&lt;/code&gt;&amp;hellip;&lt;/p&gt;</description></item><item><title>sleepsort</title><link>https://lbolla-info.netlify.app/blog/sleepsort/</link><pubDate>Fri, 17 Jun 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/sleepsort/</guid><description>&lt;p&gt;To honor &lt;a href="http://dis.4chan.org/read/prog/1295544154"&gt;the funniest thread in months&lt;/a&gt;, here is a lisp implementation of &lt;a href="http://en.wikipedia.org/wiki/Sleep_sort"&gt;sleepsort&lt;/a&gt;!&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;(use-package :sb-thread)

(defun show (item)
 (sleep item)
 (format t &amp;#34;~S~%&amp;#34; item))

(defun sleep-sort (lst)
 (mapcar
 #&amp;#39;(lambda (item) (make-thread #&amp;#39;(lambda () (show item))))
 lst))
&lt;/code&gt;&lt;/pre&gt;</description></item><item><title>Javascript templating benchmark</title><link>https://lbolla-info.netlify.app/blog/javascript-templating-benchmark/</link><pubDate>Mon, 23 May 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/javascript-templating-benchmark/</guid><description>&lt;p&gt;There are many popular libraries to do templating in Javascript.&lt;/p&gt;
&lt;p&gt;The most popular are:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="http://api.jquery.com/jQuery.template/"&gt;JQuery Template&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.javascriptr.com/2008/06/05/purejstemplate-a-pure-javascript-templating-engine-for-jquery/"&gt;Pure Template&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://ejohn.org/blog/javascript-micro-templating/"&gt;Resig Template&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://code.google.com/p/trimpath/wiki/JavaScriptTemplates"&gt;Trimpath Template&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://aefxx.com/jquery-plugins/jqote2/"&gt;JQote2 Template&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I decided to benchmark them, so I created a simple &amp;quot;hello world&amp;quot; test.&lt;/p&gt;
&lt;p&gt;As usual, the results are interesting. Here are, on my box:&lt;/p&gt;
&lt;table&gt;
	&lt;thead&gt;
			&lt;tr&gt;
					&lt;th&gt;&lt;/th&gt;
					&lt;th&gt;Firefox 3.6&lt;/th&gt;
					&lt;th&gt;Chrome 11.0&lt;/th&gt;
					&lt;th&gt;Safari 5.0&lt;/th&gt;
			&lt;/tr&gt;
	&lt;/thead&gt;
	&lt;tbody&gt;
			&lt;tr&gt;
					&lt;td&gt;jQuery Template&lt;/td&gt;
					&lt;td&gt;297ms&lt;/td&gt;
					&lt;td&gt;138ms&lt;/td&gt;
					&lt;td&gt;113ms&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;Pure&lt;/td&gt;
					&lt;td&gt;309ms&lt;/td&gt;
					&lt;td&gt;43ms&lt;/td&gt;
					&lt;td&gt;36ms&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;Resig&lt;/td&gt;
					&lt;td&gt;309ms&lt;/td&gt;
					&lt;td&gt;41ms&lt;/td&gt;
					&lt;td&gt;41ms&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;Trimpath&lt;/td&gt;
					&lt;td&gt;15ms&lt;/td&gt;
					&lt;td&gt;5ms&lt;/td&gt;
					&lt;td&gt;6ms&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;JQote2&lt;/td&gt;
					&lt;td&gt;7ms&lt;/td&gt;
					&lt;td&gt;1ms&lt;/td&gt;
					&lt;td&gt;6ms&lt;/td&gt;
			&lt;/tr&gt;
	&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;A part from the obvious result that Firefox is the slowest browser of all, I'm astonished by the excellent performance of JQote2!&lt;/p&gt;</description></item><item><title>Related to... Andrew Lloyd Webber!</title><link>https://lbolla-info.netlify.app/blog/related-to...-andrew-lloyd-webber/</link><pubDate>Tue, 12 Apr 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/related-to...-andrew-lloyd-webber/</guid><description>&lt;p&gt;It looks like I'm &lt;a href="http://www.google.com/help/features.html"&gt;related&lt;/a&gt; to &lt;a href="http://www.google.co.uk/search?sourceid=chrome&amp;amp;ie=UTF-8&amp;amp;q=related%3Albolla.info"&gt;Andrew Lloyd Webber&lt;/a&gt;! Funny it's in Portuguese, though&amp;hellip;&lt;/p&gt;</description></item><item><title>Get registered domain in Python and Javascript</title><link>https://lbolla-info.netlify.app/blog/get-registered-domain-in-python-and-javascript/</link><pubDate>Tue, 05 Apr 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/get-registered-domain-in-python-and-javascript/</guid><description>&lt;p&gt;&lt;a href="http://www.dkim-reputation.org/regdom-libs/"&gt;reg-dom-libs&lt;/a&gt; are a set of libraries for &lt;code&gt;C&lt;/code&gt;, &lt;code&gt;PHP&lt;/code&gt; and &lt;code&gt;Perl&lt;/code&gt; to convert an arbitrary domain name to the registered domain name.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;For simple domains, like &lt;code&gt;www.amazon.com&lt;/code&gt; or &lt;code&gt;news.ycombinator.com&lt;/code&gt;, the task is trivial.&lt;/li&gt;
&lt;li&gt;For more complicated ones, like &lt;code&gt;www.ebay.co.uk&lt;/code&gt; or &lt;code&gt;www.japantimes.co.jp&lt;/code&gt;, handling the second level subdomain is a little painful.&lt;/li&gt;
&lt;li&gt;For exoteric ones, like &lt;code&gt;nic.com.ai&lt;/code&gt; or &lt;code&gt;www.nic.net.ge&lt;/code&gt; or &lt;code&gt;公司.cn&lt;/code&gt;, the problem becomes virtually impossible.&lt;/li&gt;
&lt;li&gt;After seeing stupid ones, like &lt;code&gt;www.comune.caserta.it&lt;/code&gt; (believe it or not, the registered domain is &lt;code&gt;comune.caserta.it&lt;/code&gt;!), I gave up finding an elegant algorithm for the problem.&lt;/li&gt;
&lt;li&gt;A full list of valid registered domain is necessary. Luckily, it is available (and nightly updated) &lt;a href="http://mxr.mozilla.org/mozilla-central/source/netwerk/dns/effective_tld_names.dat?raw=1"&gt;here&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Inspired by &lt;a href="http://www.dkim-reputation.org/regdom-libs/"&gt;reg-dom-libs&lt;/a&gt;, I've ported the algorithm to &lt;a href="https://github.com/lbolla/junk/blob/master/utils/regdomain.py"&gt;Python&lt;/a&gt; and &lt;a href="https://github.com/lbolla/junk/blob/master/utils/regdomain.js"&gt;Javascript&lt;/a&gt;. See the tests at the end of each file for an example of the usage. A demo is available &lt;a href="file:///junk/regdomain/"&gt;here&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Handling an iframe from the inside</title><link>https://lbolla-info.netlify.app/blog/handling-an-iframe-from-the-inside/</link><pubDate>Wed, 30 Mar 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/handling-an-iframe-from-the-inside/</guid><description>&lt;p&gt;If you've ever worked with &lt;code&gt;iframes&lt;/code&gt; you've certainly run into the &lt;a href="http://en.wikipedia.org/wiki/Same_origin_policy"&gt;same origin policy&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;From &lt;a href="http://www.onlineaspect.com/2010/01/15/backwards-compatible-postmessage/"&gt;here&lt;/a&gt;:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;The same origin policy basically limits how scripts and frames on different domains can talk to each other.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;This is particularly bad if you want to resize an &lt;code&gt;iframe&lt;/code&gt; to accomodate its content, as this is not doable with simple CSS (to the best of my knowledge!). It can be done using &lt;a href="https://developer.mozilla.org/en/DOM/window.postMessage"&gt;&lt;code&gt;window.postMessage&lt;/code&gt;&lt;/a&gt;, though.&lt;/p&gt;
&lt;p&gt;&lt;a href="file:///junk/iframe/"&gt;See a demo here&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>twill revived</title><link>https://lbolla-info.netlify.app/blog/twill-revived/</link><pubDate>Fri, 11 Mar 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/twill-revived/</guid><description>&lt;p&gt;After reading &lt;a href="https://docs.google.com/viewer?url=http://adam.therobots.org/talks/testing.pdf"&gt;how to do automated testing in python&lt;/a&gt;, I've started using &lt;a href="http://twill.idyll.org/"&gt;twill&lt;/a&gt;, by &lt;a href="mailto:titus@idyll.org"&gt;C. Titus Brown&lt;/a&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;twill is a simple language that allows users to browse the Web from a command-line interface. With twill, you can navigate through Web sites that use forms, cookies, and most standard Web features.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Unfortunately, development on twill seems to have stopped 3 years ago.&lt;/p&gt;
&lt;p&gt;I've &lt;a href="http://github.com/lbolla/twill"&gt;cloned the project on Github&lt;/a&gt;, fixed some deprecation warnings and added a cool new feature to inspect headers, as well as html.&lt;/p&gt;</description></item><item><title>Year 2038 bug in MySQL</title><link>https://lbolla-info.netlify.app/blog/year-2038-bug-in-mysql/</link><pubDate>Fri, 04 Mar 2011 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/year-2038-bug-in-mysql/</guid><description>&lt;p&gt;Today I hit the &lt;a href="http://2038bug.com/"&gt;&amp;quot;year 2038&amp;quot; bug&lt;/a&gt;. While working on MySQL, I did something like:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-sql" data-lang="sql"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;mysql&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;create&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;table&lt;/span&gt; y2038 (x &lt;span style="color:#66d9ef"&gt;timestamp&lt;/span&gt;);
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;mysql&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;insert&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;into&lt;/span&gt; y2038 &lt;span style="color:#66d9ef"&gt;values&lt;/span&gt; (&lt;span style="color:#e6db74"&gt;&amp;#39;1900-01-01&amp;#39;&lt;/span&gt;);
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;Query OK, &lt;span style="color:#ae81ff"&gt;1&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;row&lt;/span&gt; affected, &lt;span style="color:#ae81ff"&gt;1&lt;/span&gt; warning (&lt;span style="color:#ae81ff"&gt;0&lt;/span&gt;.&lt;span style="color:#ae81ff"&gt;04&lt;/span&gt; sec)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;mysql&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;insert&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;into&lt;/span&gt; y2038 &lt;span style="color:#66d9ef"&gt;values&lt;/span&gt; (&lt;span style="color:#e6db74"&gt;&amp;#39;2050-01-01&amp;#39;&lt;/span&gt;);
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;Query OK, &lt;span style="color:#ae81ff"&gt;1&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;row&lt;/span&gt; affected, &lt;span style="color:#ae81ff"&gt;1&lt;/span&gt; warning (&lt;span style="color:#ae81ff"&gt;0&lt;/span&gt;.&lt;span style="color:#ae81ff"&gt;04&lt;/span&gt; sec)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;mysql&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;select&lt;/span&gt; &lt;span style="color:#f92672"&gt;*&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;from&lt;/span&gt; y2038;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;+&lt;/span&gt;&lt;span style="color:#75715e"&gt;---------------------+
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;|&lt;/span&gt; x &lt;span style="color:#f92672"&gt;|&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;+&lt;/span&gt;&lt;span style="color:#75715e"&gt;---------------------+
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;|&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;0000&lt;/span&gt;&lt;span style="color:#f92672"&gt;-&lt;/span&gt;&lt;span style="color:#ae81ff"&gt;00&lt;/span&gt;&lt;span style="color:#f92672"&gt;-&lt;/span&gt;&lt;span style="color:#ae81ff"&gt;00&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;00&lt;/span&gt;:&lt;span style="color:#ae81ff"&gt;00&lt;/span&gt;:&lt;span style="color:#ae81ff"&gt;00&lt;/span&gt; &lt;span style="color:#f92672"&gt;|&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;|&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;0000&lt;/span&gt;&lt;span style="color:#f92672"&gt;-&lt;/span&gt;&lt;span style="color:#ae81ff"&gt;00&lt;/span&gt;&lt;span style="color:#f92672"&gt;-&lt;/span&gt;&lt;span style="color:#ae81ff"&gt;00&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;00&lt;/span&gt;:&lt;span style="color:#ae81ff"&gt;00&lt;/span&gt;:&lt;span style="color:#ae81ff"&gt;00&lt;/span&gt; &lt;span style="color:#f92672"&gt;|&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;+&lt;/span&gt;&lt;span style="color:#75715e"&gt;---------------------+
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#ae81ff"&gt;2&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;row&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;in&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;set&lt;/span&gt; (&lt;span style="color:#ae81ff"&gt;0&lt;/span&gt;.&lt;span style="color:#ae81ff"&gt;00&lt;/span&gt; sec)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;mysql&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;drop&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;table&lt;/span&gt; y2038; &lt;span style="color:#75715e"&gt;-- damn
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;&lt;a href="http://dev.mysql.com/doc/refman/5.0/en/datetime.html"&gt;It turned out&lt;/a&gt; that MySQL's &lt;code&gt;TIMESTAMP&lt;/code&gt; only accepts dates between &lt;code&gt;1970-01-01 00:00:01&lt;/code&gt; and &lt;code&gt;2038-01-19 03:14:07&lt;/code&gt;: everything outside this range will be truncated.&lt;/p&gt;</description></item><item><title>SBCL quicker than C?</title><link>https://lbolla-info.netlify.app/blog/sbcl-quicker-than-c/</link><pubDate>Sun, 05 Dec 2010 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/sbcl-quicker-than-c/</guid><description>&lt;p&gt;After reading a &lt;a href="http://groups.google.com/group/comp.lang.lisp/browse_thread/thread/f5a2d25909ce00d2/61aee068b573f89a"&gt;nice conversation on comp.lang.lisp&lt;/a&gt; I decided to play a little bit with SBCL and &lt;a href="http://shootout.alioth.debian.org/"&gt;Debian's Shootout Benchmarks&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;I considered the &lt;a href="http://shootout.alioth.debian.org/u32/benchmark.php?test=spectralnorm&amp;amp;lang=sbcl&amp;amp;lang2=gcc"&gt;spectral norm benchmark&lt;/a&gt; and compared the C and SBCL implementations.&lt;/p&gt;
&lt;p&gt;I started re-running the tests without any further optimization and the results were similar to the ones reported with C beating SBCL by a factor of 2. (for the C optimization used, see &lt;a href="http://shootout.alioth.debian.org/u32/benchmark.php?test=spectralnorm&amp;amp;lang=gcc"&gt;here&lt;/a&gt;).&lt;/p&gt;
&lt;p&gt;Then, I noticed that there was no =(declaim (optimize (speed 3) (safety 0) (space 0)))= in the SBCL file! I've added it and rerun the test. Here are my results:&lt;/p&gt;</description></item><item><title>Find hyperlinks with lisp</title><link>https://lbolla-info.netlify.app/blog/find-hyperlinks-with-lisp/</link><pubDate>Sun, 24 Oct 2010 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/find-hyperlinks-with-lisp/</guid><description>&lt;p&gt;Here is a quick-and-dirty script to extract all the unique links from a web page.&lt;/p&gt;
&lt;p&gt;It uses &lt;a href="http://weitz.de/cl-ppcre/"&gt;cl-ppcre&lt;/a&gt; to extract the hyperlinks-like strings from a target string. Tested using &lt;a href="http://weitz.de/drakma/"&gt;drakma&lt;/a&gt; as web client.&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;(asdf:oos &amp;#39;asdf:load-op :drakma)
(asdf:oos &amp;#39;asdf:load-op :cl-ppcre)

(defparameter *url-re* &amp;#34;href *= *[&amp;#39;&amp;#34;](\S+)[&amp;#39;&amp;#34;]&amp;#34;)

(defun find-links (str)
 (let ((urls &amp;#39;()))
 (ppcre:do-register-groups
 (u) (*url-re* str nil :start 0 :sharedp t)
 (pushnew u urls :test #&amp;#39;equalp))
 (nreverse urls)))

(print
 (find-links (drakma:http-request &amp;#34;http://lbolla.wordpress.com&amp;#34;)))
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;There are 139 links on this page&amp;hellip;&lt;/p&gt;</description></item><item><title>lisp threading example</title><link>https://lbolla-info.netlify.app/blog/lisp-threading-example/</link><pubDate>Sat, 23 Oct 2010 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/lisp-threading-example/</guid><description>&lt;p&gt;Today I wanted to experiment with threads in lisp (&lt;a href="http://www.sbcl.org/"&gt;sbcl&lt;/a&gt;, in particular).&lt;/p&gt;
&lt;p&gt;Here is a trivial example of how to access a shared resource (a closure, keeping a list of integers), from a set of &lt;code&gt;*nt*&lt;/code&gt; threads.&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;(use-package :sb-thread)

;; number of threads
(defparameter *nt* 10)

;; threads
(defvar *threads* &amp;#39;())

;; mutex to use with shared resource accessed by the threads
(defvar *a-mutex* (make-mutex :name &amp;#34;acc-lock&amp;#34;))

;; shared closure accessed by the threads
(let ((x &amp;#39;()))
 (defun acc (v)
 (with-mutex (*a-mutex*)
 (push v x)))
 (defun get-acc ()
 x))

;; print the shared resource
(print (get-acc))

;; wait for all the threads to return
(mapcar #&amp;#39;join-thread
 ;; run the threads
 (loop :for i :below *nt* 
 ;; bind i to x so it is local to the thread
 :collect (let ((x i))
 (make-thread #&amp;#39;(lambda ()
 ;; body of the thread
 (sleep (random 2))
 (acc x))
 :name x))))

;; print the shared resource
(print (get-acc))
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;It can't get much simpler than that&amp;hellip;&lt;/p&gt;</description></item><item><title>Simple Wordpress API lisp client</title><link>https://lbolla-info.netlify.app/blog/simple-wordpress-api-lisp-client/</link><pubDate>Wed, 04 Aug 2010 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/simple-wordpress-api-lisp-client/</guid><description>&lt;p&gt;I like old things, therefore I started to learn Lisp.&lt;/p&gt;
&lt;p&gt;There isn't a better way to learn than by doing, so I tried to implement a client for the &lt;a href="http://codex.wordpress.org/XML-RPC_Support"&gt;wordpress api&lt;/a&gt;. the result, even if not complete yet, it's so elegant that I'd like to &lt;a href="http://github.com/lbolla/junk/blob/master/lisp/wordpress.lisp"&gt;share it&lt;/a&gt;.&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;(require &amp;#39;s-xml-rpc)

(defpackage :wp 
 (:use :cl :cl-user :s-xml-rpc))

(in-package :wp)

(defparameter +interfaces+ 
 &amp;#39;((get-blogs &amp;#34;wp.getUsersBlogs&amp;#34; username password)
 (get-tags &amp;#34;wp.getTags&amp;#34; blog-id username password)
 (get-comment-count &amp;#34;wp.getCommentCount&amp;#34; blog-id username password post-id)
 (get-post-status-list &amp;#34;wp.getPostStatusList&amp;#34; blog-id username password)
 (get-page-status-list &amp;#34;wp.getPageStatusList&amp;#34; blog-id username password)
 (get-page-templates &amp;#34;wp.getPageTemplates&amp;#34; blog-id username password)
 (get-options &amp;#34;wp.getOptions&amp;#34; blog-id username password)
 (delete-comment &amp;#34;wp.deleteComment&amp;#34; blog-id username password comment-id)
 (get-comment-status-list &amp;#34;wp.getCommentStatusList&amp;#34; blog-id username password)
 (get-page &amp;#34;wp.getPage&amp;#34; blog-id page-id username password)
 (get-pages &amp;#34;wp.getPages&amp;#34; blog-id username password)
 (get-page-list &amp;#34;wp.getPageList&amp;#34; blog-id username password)
 (delete-page &amp;#34;wp.deletePage&amp;#34; blog-id username password page-id)
 (get-authors &amp;#34;wp.getAuthors&amp;#34; blog-id username password)
 (get-categories &amp;#34;wp.getCategories&amp;#34; blog-id username password)
 (delete-category &amp;#34;wp.deleteCategory&amp;#34; blog-id username password category-id)
 (suggest-categories &amp;#34;wp.suggestCategories&amp;#34; blog-id username password category max-results)
 (get-comment &amp;#34;wp.getComment&amp;#34; blog-id username password comment-id))
 &amp;#34;Interface definition to WP services&amp;#34;)

(defun defunwp (params) 
 (destructuring-bind (name service &amp;amp;rest rest) params
 (setf (fdefinition name) (compile nil `(lambda (host ,@rest &amp;amp;optional (url &amp;#34;/xmlrpc.php&amp;#34;)) 
 (block ,name 
 (xml-rpc-call 
 (encode-xml-rpc-call ,service ,@rest)
 :host host
 :url url)))))
 name))

(mapcar #&amp;#39;(lambda (interface) (export (defunwp interface))) +interfaces+)
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;It uses the &lt;a href="http://common-lisp.net/project/s-xml-rpc/"&gt;s-xml-rpc&lt;/a&gt; package and I've tested it with &lt;a href="http://www.sbcl.org/"&gt;SBCL&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Missing `Dec_0` and friends from Python Decimal</title><link>https://lbolla-info.netlify.app/blog/missing-dec_0-and-friends-from-python-decimal/</link><pubDate>Thu, 29 Jul 2010 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/missing-dec_0-and-friends-from-python-decimal/</guid><description>&lt;p&gt;This fails in &lt;code&gt;py2.4&lt;/code&gt;, &lt;code&gt;py2.5.1&lt;/code&gt; and &lt;code&gt;py2.6&lt;/code&gt;:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-python" data-lang="python"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;from&lt;/span&gt; decimal &lt;span style="color:#f92672"&gt;import&lt;/span&gt; Dec_0
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;But it works in all the other &lt;code&gt;py2.5&lt;/code&gt; subversions!&lt;/p&gt;
&lt;p&gt;It seems that exposing &lt;code&gt;Dec_0&lt;/code&gt; (and other similar constants) was considered a &lt;a href="http://bugs.python.org/issue4812"&gt;bug&lt;/a&gt; and &amp;quot;fixed&amp;quot; on Jan 3rd 2009 by renaming it &lt;code&gt;_Dec_0&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;Indeed, if I had looked at the source code, I would have seen that &lt;code&gt;Dec_0&lt;/code&gt; was for &amp;quot;internal use only&amp;quot;.&lt;/p&gt;
&lt;p&gt;From &lt;code&gt;/usr/lib/python2.5/decimal.py:5159&lt;/code&gt;&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-python" data-lang="python"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;# Reusable defaults&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;Inf &lt;span style="color:#f92672"&gt;=&lt;/span&gt; Decimal(&lt;span style="color:#e6db74"&gt;&amp;#39;Inf&amp;#39;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;negInf &lt;span style="color:#f92672"&gt;=&lt;/span&gt; Decimal(&lt;span style="color:#e6db74"&gt;&amp;#39;-Inf&amp;#39;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;NaN &lt;span style="color:#f92672"&gt;=&lt;/span&gt; Decimal(&lt;span style="color:#e6db74"&gt;&amp;#39;NaN&amp;#39;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;Dec_0 &lt;span style="color:#f92672"&gt;=&lt;/span&gt; Decimal(&lt;span style="color:#ae81ff"&gt;0&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;Dec_p1 &lt;span style="color:#f92672"&gt;=&lt;/span&gt; Decimal(&lt;span style="color:#ae81ff"&gt;1&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;Dec_n1 &lt;span style="color:#f92672"&gt;=&lt;/span&gt; Decimal(&lt;span style="color:#f92672"&gt;-&lt;/span&gt;&lt;span style="color:#ae81ff"&gt;1&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Those definitions are missing in &lt;code&gt;py2.4&lt;/code&gt; and &lt;code&gt;py2.5.1&lt;/code&gt;, and renamed in &lt;code&gt;py2.6&lt;/code&gt;.&lt;/p&gt;</description></item><item><title>Wordpress Python library</title><link>https://lbolla-info.netlify.app/blog/wordpress-python-library/</link><pubDate>Sun, 06 Jun 2010 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/wordpress-python-library/</guid><description>&lt;p&gt;Today, I found &lt;a href="http://www.blackbirdblog.it/programmazione/progetti/28"&gt;this&lt;/a&gt;. It's a wonderfully simple Python library to manage your Wordpress blog via &lt;a href="http://www.xmlrpc.com"&gt;XML-RPC&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Enjoy!&lt;/p&gt;</description></item><item><title>Editors speed on opening big files</title><link>https://lbolla-info.netlify.app/blog/editors-speed-on-opening-big-files/</link><pubDate>Mon, 17 May 2010 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/editors-speed-on-opening-big-files/</guid><description>&lt;p&gt;While playing with different editors (namely &lt;a href="http://www.vim.org"&gt;vim&lt;/a&gt; and &lt;a href="http://sam.cat-v.org/"&gt;sam&lt;/a&gt;) I tried to time how long some common editors take to open a big file (~140Mb).&lt;/p&gt;
&lt;p&gt;Then, for curiosity, I timed &lt;code&gt;less&lt;/code&gt; with and without (&lt;code&gt;-n&lt;/code&gt;) line numbering:&lt;/p&gt;
&lt;p&gt;Here are the results:&lt;/p&gt;
&lt;table&gt;
	&lt;thead&gt;
			&lt;tr&gt;
					&lt;th&gt;editor&lt;/th&gt;
					&lt;th&gt;real&lt;/th&gt;
					&lt;th&gt;user&lt;/th&gt;
					&lt;th&gt;sys&lt;/th&gt;
			&lt;/tr&gt;
	&lt;/thead&gt;
	&lt;tbody&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;ed&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;4.866s&lt;/td&gt;
					&lt;td&gt;3.440s&lt;/td&gt;
					&lt;td&gt;3.440s&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;vim&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;2.086s&lt;/td&gt;
					&lt;td&gt;0.836s&lt;/td&gt;
					&lt;td&gt;0.232s&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;nano&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;16.264s&lt;/td&gt;
					&lt;td&gt;15.361s&lt;/td&gt;
					&lt;td&gt;0.172s&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;sam&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;way too long&lt;/td&gt;
					&lt;td&gt;&lt;/td&gt;
					&lt;td&gt;&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;less&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;3.552s&lt;/td&gt;
					&lt;td&gt;0.200s&lt;/td&gt;
					&lt;td&gt;0.072s&lt;/td&gt;
			&lt;/tr&gt;
			&lt;tr&gt;
					&lt;td&gt;&lt;code&gt;less -n&lt;/code&gt;&lt;/td&gt;
					&lt;td&gt;0.182s&lt;/td&gt;
					&lt;td&gt;0.016s&lt;/td&gt;
					&lt;td&gt;0.016s&lt;/td&gt;
			&lt;/tr&gt;
	&lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;Not sure what to do with these numbers, yet&amp;hellip;&lt;/p&gt;</description></item><item><title>Trivial terminal speed benchmark</title><link>https://lbolla-info.netlify.app/blog/trivial-terminal-speed-benchmark/</link><pubDate>Thu, 29 Apr 2010 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/trivial-terminal-speed-benchmark/</guid><description>&lt;p&gt;Today, while playing with &lt;a href="http://st.suckless.org"&gt;st&lt;/a&gt;, I tried a very simple benchmark. Here it is:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-shell" data-lang="shell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;$&amp;gt; time seq -f &lt;span style="color:#e6db74"&gt;&amp;#39;teeeeeeeeeeeeeeeeeeeeeeeeeeeeeest %g&amp;#39;&lt;/span&gt; &lt;span style="color:#ae81ff"&gt;999999&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Here are the results:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-shell" data-lang="shell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;xterm: 0m28.508s
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;rxvt: 0m8.568s
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;st: 0m12.082s
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;All the terminals shared the same fonts, but &lt;a href="http://invisible-island.net/xterm/"&gt;xterm&lt;/a&gt; and &lt;a href="http://sourceforge.net/projects/rxvt/"&gt;rxvt&lt;/a&gt; had &lt;code&gt;saveLines=1024&lt;/code&gt; set for scrolling purposes, feature that &lt;a href="http://st.suckless.org"&gt;st&lt;/a&gt; lacks.&lt;/p&gt;
&lt;p&gt;Being &lt;a href="http://st.suckless.org"&gt;st&lt;/a&gt; at such an early stage of development, I think this is a good result.&lt;/p&gt;</description></item><item><title>surf browser hints -3</title><link>https://lbolla-info.netlify.app/blog/surf-browser-hints--3/</link><pubDate>Sat, 09 Jan 2010 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/surf-browser-hints--3/</guid><description>&lt;p&gt;Another couple of hints about &lt;a href="http://surf.suckless.org"&gt;&lt;code&gt;surf&lt;/code&gt;&lt;/a&gt;, after &lt;a href="https://lbolla-info.netlify.app/blog/surf-browser-hints--2/"&gt;my previous post&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Honestly, I stopped using &lt;a href="http://surf.suckless.org"&gt;&lt;code&gt;surf&lt;/code&gt;&lt;/a&gt; after 0.3 release. I think that the authors stripped out of the code too much sugar that, not being suckless, was nonetheless useful: a status bar showing the current URI, for example. Now URI editing is done via &lt;code&gt;xprop&lt;/code&gt; and &lt;a href="http://tools.suckless.org/dmenu"&gt;&lt;code&gt;dmenu&lt;/code&gt;&lt;/a&gt;, which is great piece of software, but not always user friendly (it does not have editing capabilities).&lt;/p&gt;
&lt;p&gt;Moreover bookmarking is a pain as it relies on external shell scripts. Or does it not? I realized that there is no need to use external shell scripts, as they can be &amp;quot;embedded&amp;quot; in C code. Here is how.&lt;/p&gt;</description></item><item><title>Installing pcf fonts in X</title><link>https://lbolla-info.netlify.app/blog/installing-pcf-fonts-in-x/</link><pubDate>Thu, 07 Jan 2010 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/installing-pcf-fonts-in-x/</guid><description>&lt;p&gt;As I keep forgetting, here is how to install &lt;code&gt;pcf&lt;/code&gt; fonts in X&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Create a new directory for the fonts, usually under /usr/share/fonts:&lt;/li&gt;
&lt;/ol&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-shell" data-lang="shell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;$&amp;gt; mkdir /usr/share/fonts/
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;ol&gt;
&lt;li&gt;Copy the &lt;code&gt;pcf&lt;/code&gt; file(s) into it (sometimes the &lt;code&gt;pcf&lt;/code&gt; files are gzipped):&lt;/li&gt;
&lt;/ol&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-shell" data-lang="shell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;$&amp;gt; cp /path/to/pcf/*.pcf* /usr/share/fonts/
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;ol&gt;
&lt;li&gt;Run mkfontdir, to create a fonts.dir file, used by X to find font files&lt;/li&gt;
&lt;/ol&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-shell" data-lang="shell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;$&amp;gt; mkfontdir /usr/share/fonts/
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;ol&gt;
&lt;li&gt;Add the new dir to X font path. The easiest way to do it is to stick this line in your &lt;code&gt;.xinitrc&lt;/code&gt;:&lt;/li&gt;
&lt;/ol&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-shell" data-lang="shell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;xset fp+ /usr/share/fonts/
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Now your new font should compare in &lt;code&gt;xfontsel&lt;/code&gt; and you should be able to use it as normal.&lt;/p&gt;</description></item><item><title>surf browser hints -2</title><link>https://lbolla-info.netlify.app/blog/surf-browser-hints--2/</link><pubDate>Tue, 25 Aug 2009 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/surf-browser-hints--2/</guid><description>&lt;p&gt;Following &lt;a href="https://lbolla-info.netlify.app/blog/surf-browser-hints/"&gt;yesterday's post&lt;/a&gt;, here is another useful hint about surf's usage.&lt;/p&gt;
&lt;p&gt;The following script lists the available bookmarks (from &lt;code&gt;~/.bookmarks&lt;/code&gt; file) and let's you pick one using &lt;code&gt;dmenu&lt;/code&gt;. If a new link is inserted, it is added to the list of known bookmarks, so you won't need to type it in full the next time:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-shell" data-lang="shell"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;#!/bin/sh
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;bookmarks&lt;span style="color:#f92672"&gt;=&lt;/span&gt;~/.bookmarks
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;link&lt;span style="color:#f92672"&gt;=&lt;/span&gt;&lt;span style="color:#e6db74"&gt;`&lt;/span&gt;cat $bookmarks | dmenu &lt;span style="color:#e6db74"&gt;${&lt;/span&gt;1+&lt;span style="color:#e6db74"&gt;&amp;#34;&lt;/span&gt;$@&lt;span style="color:#e6db74"&gt;&amp;#34;&lt;/span&gt;&lt;span style="color:#e6db74"&gt;}&lt;/span&gt;&lt;span style="color:#e6db74"&gt;`&lt;/span&gt; &lt;span style="color:#f92672"&gt;||&lt;/span&gt; exit &lt;span style="color:#ae81ff"&gt;0&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;present&lt;span style="color:#f92672"&gt;=&lt;/span&gt;&lt;span style="color:#e6db74"&gt;`&lt;/span&gt;grep $link $bookmarks&lt;span style="color:#e6db74"&gt;`&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;if&lt;/span&gt; &lt;span style="color:#f92672"&gt;[&lt;/span&gt; &lt;span style="color:#e6db74"&gt;&amp;#34;&lt;/span&gt;$?&lt;span style="color:#e6db74"&gt;&amp;#34;&lt;/span&gt; -ne &lt;span style="color:#e6db74"&gt;&amp;#34;0&amp;#34;&lt;/span&gt; &lt;span style="color:#f92672"&gt;]&lt;/span&gt;; &lt;span style="color:#66d9ef"&gt;then&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; echo $link &amp;gt;&amp;gt; $bookmarks
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;fi&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;surf -u $link
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;If you don't want to open a new window, just change the last line to set the &lt;code&gt;_SURF_URL&lt;/code&gt; X Property of the surf window you want to use (by clicking on it):&lt;/p&gt;</description></item><item><title>surf browser hints</title><link>https://lbolla-info.netlify.app/blog/surf-browser-hints/</link><pubDate>Mon, 24 Aug 2009 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/surf-browser-hints/</guid><description>&lt;p&gt;&lt;a href="http://surf.suckless.org"&gt;&lt;code&gt;surf&lt;/code&gt;&lt;/a&gt; is a simple web browser based on &lt;a href="http://en.wikipedia.org/wiki/Webkit"&gt;webkit&lt;/a&gt;/gtk+, the same web engine that powers &lt;a href="http://www.google.co.uk/chrome"&gt;Google Chrome&lt;/a&gt;. Used with &lt;a href="http://dwm.suckless.org"&gt;&lt;code&gt;dwm&lt;/code&gt;&lt;/a&gt; and &lt;a href="http://tools.suckless.org/dmenu"&gt;dmenu&lt;/a&gt;, it's a very powerful, yet simple tool.&lt;/p&gt;
&lt;p&gt;Here is a patch to apply X geometry hints to &lt;code&gt;surf&lt;/code&gt;, so that &lt;code&gt;surf&lt;/code&gt; windows behave in &lt;code&gt;dwm.&lt;/code&gt;&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;*** surf.c.orig 2009-08-24 16:41:31.000000000 +0100
--- surf.c 2009-08-24 16:35:02.000000000 +0100
***************
*** 372,377 ****
--- 372,381 ----
gtk_container_add(GTK_CONTAINER(c-&amp;gt;vbox), c-&amp;gt;searchbar);
gtk_container_add(GTK_CONTAINER(c-&amp;gt;vbox), c-&amp;gt;urlbar);

+ /* Hints */
+ GdkGeometry hints = { 1, 1 };
+ gtk_window_set_geometry_hints(GTK_WINDOW(c-&amp;gt;win), NULL, &amp;amp;hints,
 GDK_HINT_MIN_SIZE);
+
/* Setup */
gtk_box_set_child_packing(GTK_BOX(c-&amp;gt;vbox), c-&amp;gt;urlbar, FALSE, FALSE, 0,
GTK_PACK_START);
gtk_box_set_child_packing(GTK_BOX(c-&amp;gt;vbox), c-&amp;gt;searchbar, FALSE, FALSE, 0,
GTK_PACK_START);
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Another hint is to create a script to feed &lt;code&gt;surf&lt;/code&gt; with your favorite bookmarks.&lt;/p&gt;</description></item><item><title>vim and Python comments</title><link>https://lbolla-info.netlify.app/blog/vim-and-python-comments/</link><pubDate>Wed, 12 Aug 2009 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/vim-and-python-comments/</guid><description>&lt;p&gt;I'm currently undergoing a profound revision (read &amp;quot;cleanup&amp;quot;) of my &lt;code&gt;.vimrc&lt;/code&gt; and I recently had to choose a decent plug-in to comment python code.&lt;/p&gt;
&lt;p&gt;The best so far is &lt;a href="http://www.vim.org/scripts/script.php?script_id=23http://www.vim.org/scripts/script.php?script_id=23"&gt;EnhancedCommentify&lt;/a&gt;. It's highly configurable, powerful and it supports a different number of languages (not only python).&lt;/p&gt;
&lt;p&gt;The only one thing that wasn't easy to setup if the behaviour described &lt;a href="http://chistera.yi.org/~adeodato/blog/entries/2008/03/02/vim_enhanced_commentify_UseBlockIndent_with_nmap.html"&gt;here&lt;/a&gt;: being able to comment a block, respecting the indent, in both visual and normal mode.&lt;/p&gt;</description></item><item><title>Test with gnome-blog</title><link>https://lbolla-info.netlify.app/blog/test-with-gnome-blog/</link><pubDate>Tue, 03 Feb 2009 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/test-with-gnome-blog/</guid><description>&lt;p&gt;This is a post using &lt;a href="http://www.gnome.org/~seth/gnome-blog/"&gt;gnome-blog&lt;/a&gt;, a weblog client for gnome. &lt;a href="http://codex.wordpress.org/Weblog_Client"&gt;Here&lt;/a&gt; I read about this possibility, but there were no instructions about how to configure the client&amp;hellip;&lt;/p&gt;
&lt;p&gt;If this is published, it can't be so difficult&amp;hellip;&lt;/p&gt;</description></item><item><title>qwerty vs dvorak vs colemak to edit Python code</title><link>https://lbolla-info.netlify.app/blog/qwerty-vs-dvorak-vs-colemak-to-edit-python-code/</link><pubDate>Mon, 02 Feb 2009 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/qwerty-vs-dvorak-vs-colemak-to-edit-python-code/</guid><description>&lt;p&gt;Yesterday, I was intrigued by the idea of choosing a more efficient keyboard layout to work with everyday. As long as I type Python code 90% of my time, I decided to evaluate the efficiency of the first 3 most widespread keyboard layouts: &lt;a href="http://en.wikipedia.org/wiki/QWERTY"&gt;QWERTY&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/Dvorak_Simplified_Keyboard"&gt;Dvorak&lt;/a&gt; and &lt;a href="http://en.wikipedia.org/wiki/Colemak"&gt;Colemak&lt;/a&gt;. I used &lt;a href="http://www.codeaxe.co.uk/dvorak/"&gt;this excellent tool&lt;/a&gt; to compare the three layouts over the first 50000 characters of the &lt;a href="http://webpy.org/"&gt;webpy&lt;/a&gt; source code. Here are the results:&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt; &amp;lt;div id=&amp;#34;page&amp;#34;&amp;gt;
 &amp;lt;div id=&amp;#34;text&amp;#34;&amp;gt;
 &amp;lt;h1&amp;gt;
The Qwerty Keyboard Layout Vs The Dvorak Keyboard Layout
 &amp;lt;/h1&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;
:: UP ::Overall effort
 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;thead class=&amp;#34;small&amp;#34;&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;
Layout
 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;
Effort
 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


% improvement over worst layout


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/thead&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Qwerty


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


306,509.6


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Dvorak


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


283,868.7


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


7.4 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Colemak


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


275,347.6


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


10.2 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::Keys for each finger (stronger fingers should be used more often)


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;thead class=&amp;#34;small&amp;#34;&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Layout


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


Thumbs


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


LPinky


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


LRing


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


LMiddle


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


LIndex


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


RIndex


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


RMiddle


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


RRing


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


RPinky


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Total


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/thead&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Qwerty


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


25.9 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


12.4 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


5.3 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


9.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


11.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


7.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


5.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


8.9 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


13.2 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


54,237.0 keys


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Dvorak


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


25.9 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


13.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


5.2 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


8.1 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


7.3 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


7.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


7.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


8.2 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


17.3 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


54,237.0 keys


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Colemak


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


25.9 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


12.7 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


4.8 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


7.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


9.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


8.4 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


10.1 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


6.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


14.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


54,237.0 keys


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;thead class=&amp;#34;small&amp;#34;&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Layout


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


Thumbs


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Left hand


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


Right hand


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Total


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/thead&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Qwerty


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


25.9 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


38.8 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


35.2 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


54,237.0 keys


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Dvorak


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


25.9 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


33.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


40.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


54,237.0 keys


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Colemak


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


25.9 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


34.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


39.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


54,237.0 keys


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::Finger Travel Distance (only the horizontal)


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;thead class=&amp;#34;small&amp;#34;&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Layout


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


Thumbs


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


LPinky


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


LRing


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


LMiddle


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


LIndex


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


RIndex


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


RMiddle


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


RRing


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


RPinky


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Total


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/thead&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Qwerty


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


18.1 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


10.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


15.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


12.1 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


8.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


9.9 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


23.4 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1,441.5 m


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Dvorak


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


21.1 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


4.1 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


3.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


10.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


12.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


7.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


10.8 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


30.4 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1,210.3 m


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Colemak


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


23.7 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


6.1 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


10.2 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


10.2 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


9.3 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


9.3 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


28.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1,131.2 m


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;thead class=&amp;#34;small&amp;#34;&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Layout


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


Thumbs


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Left hand


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;


Right hand


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Total


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/thead&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Qwerty


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


46.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


54.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1,441.5 m


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Dvorak


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


38.8 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


61.2 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1,210.3 m


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34;&amp;gt;


Colemak


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


42.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


57.4 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a1&amp;#34; style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1,131.2 m


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;a0&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::% home keys (out of all character keys plus SHIFT and ENTER, but excluding keys operated by thumbs)


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Qwerty


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


20.4 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Dvorak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


33.7 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Colemak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


38.7 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::% keys typed with the same finger as the previous key (excluding repeating keys like ss)


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Qwerty


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


4.5 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Dvorak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


3.8 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Colemak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


3.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::% keys typed with the same hand as the previous key (ex: in Qwerty sd or ss are included, but s s is not since you type the space with the other hand)


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Qwerty


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


26.8 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Dvorak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


20.0 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Colemak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


24.6 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::% keys typed with the same hand as the previous key and jumping a row (ex: in Qwerty ev is a row jump -- you jump over the middle row -- and it&amp;#39;s awkward to type; ef is not a row jump)


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Qwerty


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


10.3 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Dvorak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


5.7 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Colemak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


4.1 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::% keys typed with the same hand as the previous key and in reverse order (ex: in Qwerty df or kj are typed in the easier order pinky-ring-middle-index, whereas fd and jk are in reverse order index-middle-ring-pinky, and harder to type)


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Qwerty


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


15.4 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Dvorak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


11.9 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Colemak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


15.2 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::% keys that need the SHIFT modifier


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Qwerty


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


14.3 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Dvorak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


14.3 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


Colemak


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


14.3 %


 &amp;lt;/td&amp;gt;
 &amp;lt;td class=&amp;#34;bar&amp;#34;&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::Pairs of consecutive keys typed with the same finger in Qwerty


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


:/NewLine/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


253 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.47 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


de


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


200 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.37 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


tr


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


158 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.29 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


rt


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


102 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.19 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


ol


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


99 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.18 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


un


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


98 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.18 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


q\_LeftShift\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


87 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.16 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


ce


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


86 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.16 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


“/NewLine/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


81 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.15 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


ed


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


80 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.15 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


}/NewLine/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


62 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.11 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::Pairs of consecutive keys typed with the same finger in Dvorak


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


ct


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


196 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.36 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


s\_RightShift\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


169 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.31 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


db


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


152 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.28 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


l\_RightShift\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


137 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.25 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


‘/LeftShift/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


133 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.25 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


rn


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


115 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.21 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


ls


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


100 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.18 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


}/NewLine/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


62 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.11 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


=/RightShift/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


59 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.11 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


“/LeftShift/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


58 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.11 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


e.


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


58 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.11 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::Pairs of consecutive keys typed with the same finger in Colemak


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


:/NewLine/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


253 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.47 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


ue


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


237 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.44 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


db


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


152 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.28 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


e,


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


89 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.16 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


q\_LeftShift\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


87 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.16 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


“/NewLine/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


81 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.15 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


}/NewLine/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


62 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.11 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


]/NewLine/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


46 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.08 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


pt


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


44 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.08 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


‘/RightShift/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


41 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.08 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


“/RightShift/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


41 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.08 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::Key frequency in your text


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/Space/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


14067 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


25.94 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/LeftShift/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


4391 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


8.10 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


e


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


3239 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


5.97 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


t


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2184 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


4.03 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


s


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2170 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


4.00 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


r


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1890 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


3.48 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


a


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1619 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2.99 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


o


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1557 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2.87 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


l


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1530 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2.82 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


n


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1519 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2.80 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/NewLine/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1511 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2.79 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


i


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1372 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2.53 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/RightShift/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1357 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2.50 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


d


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1014 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.87 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


f


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


971 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.79 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


c


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


855 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.58 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


u


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


851 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.57 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


m


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


716 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.32 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


p


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


715 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.32 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


(


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


674 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.24 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


)


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


673 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.24 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


.


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


658 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.21 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


‘


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


623 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.15 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


,


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


573 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.06 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


b


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


571 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.05 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


“


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


563 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.04 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


554 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.02 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


=


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


518 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.96 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


:


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


490 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.90 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


q


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


463 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.85 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


y


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


423 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.78 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


h


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


416 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.77 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


w


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


352 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.65 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


&amp;gt;


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


348 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.64 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


g


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


304 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.56 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


v


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


257 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.47 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


x


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


253 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.47 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


k


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


231 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.43 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


&amp;lt;


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


154 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.28 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


125 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.23 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


[]


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


119 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.22 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


;


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


113 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.21 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


0


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


86 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.16 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


`


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


85 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.16 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


+


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


84 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.15 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


1


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


81 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.15 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


{


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


80 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.15 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


}


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


79 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.15 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


-


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


78 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.14 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


j


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


76 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.14 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


*


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


72 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.13 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


#


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


69 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.13 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


2


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


67 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.12 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


%


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


55 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.10 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


$


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


52 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.10 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


3


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


31 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.06 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


6


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


29 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.05 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


8


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


18 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.03 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


@


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


17 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.03 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;&amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


14 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.03 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


z


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


13 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.02 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


5


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


13 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.02 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


4


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


8 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.01 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


?


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


8 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.01 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


9


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


7 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.01 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;hr /&amp;gt;
 &amp;lt;h2 style=&amp;#34;font-size: 90%;&amp;#34;&amp;gt;


:: UP ::Frequent pairs of keys in your text


 &amp;lt;/h2&amp;gt;
 &amp;lt;table&amp;gt;
 &amp;lt;tbody&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


\_Space\_\_Space\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


9243 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


17.04 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


\_NewLine\_\_Space\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1233 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


2.27 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


\_Space\_\_LeftShift\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


805 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.48 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/LeftShift/(


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


674 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.24 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/LeftShift/)


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


673 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.24 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/LeftShift/”


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


563 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.04 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


\_LeftShift\_\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


554 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.02 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


se


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


549 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.01 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


,/Space/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


543 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


1.00 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/LeftShift/:


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


490 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.90 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


el


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


405 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.75 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


er


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


377 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.70 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


in


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


364 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.67 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


\_Space\_\_RightShift\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


362 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.67 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


or


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


352 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.65 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/LeftShift/&amp;gt;


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


348 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.64 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/Space/i


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


344 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.63 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/Space/s


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


341 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.63 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


te


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


340 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.63 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


e\_LeftShift\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


338 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.62 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


=/Space/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


332 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.61 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


/Space/=


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


321 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.59 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


re


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


306 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.56 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


lf


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


294 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.54 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


)/NewLine/


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


281 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.52 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;tr&amp;gt;
 &amp;lt;td&amp;gt;


e\_Space\_


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


281 times


 &amp;lt;/td&amp;gt;
 &amp;lt;td style=&amp;#34;text-align: right;&amp;#34;&amp;gt;


0.52 %


 &amp;lt;/td&amp;gt;
 &amp;lt;/tr&amp;gt;
 &amp;lt;/tbody&amp;gt;
 &amp;lt;/table&amp;gt;
 &amp;lt;/div&amp;gt;
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Actually, I was disappointed: there seem to be no clear advantage of Dvorak or Colemak, wrt QWERTY and, given the popularity of the latter, switching does not seem to be a good idea&amp;hellip;&lt;/p&gt;</description></item><item><title>This is another weblog client test</title><link>https://lbolla-info.netlify.app/blog/this-is-another-weblog-client-test/</link><pubDate>Sun, 01 Feb 2009 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/this-is-another-weblog-client-test/</guid><description>&lt;p&gt;&amp;hellip;and this is using &lt;a href="http://blogtk.sourceforge.net/"&gt;BloGTK&lt;/a&gt;, which seems a little bit better. It support tags, too!&lt;/p&gt;
&lt;p&gt;Better&amp;hellip;&lt;/p&gt;</description></item><item><title>Tab completion in Python shell</title><link>https://lbolla-info.netlify.app/blog/tab-completion-in-python-shell/</link><pubDate>Wed, 25 Jun 2008 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/tab-completion-in-python-shell/</guid><description>&lt;p&gt;Recently &lt;a href="http://groups.google.com/group/comp.lang.python/browse_thread/thread/b1f19db3f69cd8ce#"&gt;I saw with this little piece of code&lt;/a&gt; to give the standard python shell tab completion capabilities:&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-python" data-lang="python"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;# setup tab completion in python shell&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;import&lt;/span&gt; rlcompleter
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;import&lt;/span&gt; readline
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;readline&lt;span style="color:#f92672"&gt;.&lt;/span&gt;parse_and_bind(&lt;span style="color:#e6db74"&gt;&amp;#34;tab: complete&amp;#34;&lt;/span&gt;)
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;Obviously, you can use the environmental variable &lt;code&gt;PYTHONSTART&lt;/code&gt; to execute this few lines anytime you start your python shell.&lt;/p&gt;
&lt;p&gt;Enjoy!&lt;/p&gt;</description></item><item><title>Memoize</title><link>https://lbolla-info.netlify.app/blog/memoize/</link><pubDate>Thu, 17 Apr 2008 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/memoize/</guid><description>&lt;p&gt;Recently, from a &lt;a href="http://groups.google.it/group/scipy-user/browse_thread/thread/d1bbbe898d099904/1cb8574c84168c57?hl=it&amp;amp;lnk=gst&amp;amp;q=memoize#1cb8574c84168c57"&gt;discussion&lt;/a&gt; on the &lt;a href="http://groups.google.it/group/scipy-user"&gt;scipy-user group&lt;/a&gt; I discovered a very elegant way to code a function with memory.&lt;/p&gt;
&lt;p&gt;Let's state the problem. Suppose you need a function that remembers, for each time it has been called, the input parameters and its output. This can be very useful in many different situations:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;If it is very expensive to evaluate, you can check its memory to see if it has been previously evaluated and, if yes, get its return value without actually calling it.&lt;/li&gt;
&lt;li&gt;Inside an optimization loop, to remember all the intermediate steps of the optimization.&lt;/li&gt;
&lt;li&gt;To accumulate data on the behaviour of the function itself.&lt;/li&gt;
&lt;li&gt;To surprise friends ;-)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The function's memory can be as long as the program's running time, or it can be &amp;quot;permanent&amp;quot; if hard-coded in a file. Starting from &lt;a href="http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/466320"&gt;here&lt;/a&gt; I've put together a couple of useful classes in python that can be used as decorators.&lt;/p&gt;</description></item><item><title>India!</title><link>https://lbolla-info.netlify.app/blog/india/</link><pubDate>Thu, 10 Apr 2008 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/india/</guid><description>&lt;p&gt;&lt;a href="http://maps.google.com/staticmap?center=18.979025953255267,80.244140625&amp;amp;markers=28.635308,77.22496,red%7C9.927708,76.266918,red%7C27.177719,78.0093,red%7C25.282009,82.956337,red%7C12.61645,80.194031,red%7C10.78482,79.142029,red%7C8.400502,76.979828,red%7C9.913986,78.121727,red%7C9.286719,79.311633,red%7C8.084033,77.54187,red%7C&amp;amp;zoom=4&amp;amp;size=500x500&amp;amp;key=ABQIAAAAITb_ASiA6dCkZ7VuJlkzPhTq9fk25wIGSg_6hAqtwa_NWPtb7xRZ02wBNfD7jZf92ZjlbxH8CRwtMQ"&gt;http://maps.google.com/staticmap?center=18.979025953255267,80.244140625&amp;amp;markers=28.635308,77.22496,red|9.927708,76.266918,red|27.177719,78.0093,red|25.282009,82.956337,red|12.61645,80.194031,red|10.78482,79.142029,red|8.400502,76.979828,red|9.913986,78.121727,red|9.286719,79.311633,red|8.084033,77.54187,red|&amp;amp;zoom=4&amp;amp;size=500x500&amp;amp;key=ABQIAAAAITb_ASiA6dCkZ7VuJlkzPhTq9fk25wIGSg_6hAqtwa_NWPtb7xRZ02wBNfD7jZf92ZjlbxH8CRwtMQ&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Dopo lunghe pensate, ecco l'itinerario! Dal 26 aprile al 16 maggio.&lt;/p&gt;</description></item><item><title>IQ test</title><link>https://lbolla-info.netlify.app/blog/iq-test/</link><pubDate>Sat, 02 Feb 2008 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/iq-test/</guid><description>&lt;p&gt;Qualche giorno fa, mi sono imbattuto in questo &lt;a href="http://www.ecmselection.co.uk/high_iq_enter_and_win/brainbuster_no_25_-_remove_digits.html"&gt;test di intelligenza&lt;/a&gt;, proposto da &lt;a href="http://www.ecmselection.co.uk/"&gt;ECM&lt;/a&gt;. Riporto il testo, per semplicita':&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Using each of the numbers 1, 2, 3, 4, 5, 6, 7, 8, 9 only once, form a nine digit number A that can satisfy the following criteria:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;A is exactly divisible by 9.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Removing the rightmost digit from A forms an eight digit number B that is exactly divisible by 8.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Removing the rightmost digit from B forms a seven digit number C that is exactly divisible by 7.&lt;/p&gt;</description></item><item><title/><link>https://lbolla-info.netlify.app/musings/photopedia/</link><pubDate>Mon, 24 Dec 2007 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/musings/photopedia/</guid><description>&lt;p&gt;&lt;a href="http://www.informit.com/ShowCover.aspx?isbn=0789737256&amp;amp;type=a"&gt;http://www.informit.com/ShowCover.aspx?isbn=0789737256&amp;amp;type=a&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Finalmente, sembra che &lt;a href="http://www.amazon.com/Photopedia-Ultimate-Digital-Photography-Resource/dp/0789737256/ref=si3_rdr_bb_product"&gt;Photopedia&lt;/a&gt; stia per uscire &lt;a href="http://www.internetbookshop.it/book/9780789737250/miller-michael/photopedia-the-ultimate.html"&gt;anche in italia&lt;/a&gt;! Conterra' una delle mie prime fotografie digitali, che potete trovare &lt;a href="http://www.flickr.com/photos/lbolla/147814800/"&gt;qui&lt;/a&gt; (rigorosamente sotto Creative Commons License).&lt;/p&gt;
&lt;p&gt;Potenza della rete&amp;hellip;&lt;/p&gt;</description></item><item><title>Photopedia</title><link>https://lbolla-info.netlify.app/blog/photopedia/</link><pubDate>Mon, 24 Dec 2007 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/photopedia/</guid><description>&lt;p&gt;&lt;a href="http://www.informit.com/ShowCover.aspx?isbn=0789737256&amp;amp;type=a"&gt;http://www.informit.com/ShowCover.aspx?isbn=0789737256&amp;amp;type=a&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Finalmente, sembra che &lt;a href="http://www.amazon.com/Photopedia-Ultimate-Digital-Photography-Resource/dp/0789737256/ref=si3_rdr_bb_product"&gt;Photopedia&lt;/a&gt; stia per uscire &lt;a href="http://www.internetbookshop.it/book/9780789737250/miller-michael/photopedia-the-ultimate.html"&gt;anche in italia&lt;/a&gt;! Conterra' una delle mie prime fotografie digitali, che potete trovare &lt;a href="http://www.flickr.com/photos/lbolla/147814800/"&gt;qui&lt;/a&gt; (rigorosamente sotto Creative Commons License).&lt;/p&gt;
&lt;p&gt;Potenza della rete&amp;hellip;&lt;/p&gt;</description></item><item><title>EMpy</title><link>https://lbolla-info.netlify.app/blog/empy/</link><pubDate>Thu, 27 Sep 2007 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/empy/</guid><description>&lt;p&gt;&lt;a href="http://empy.sourceforge.net"&gt;EMpy&lt;/a&gt; is out! Here is the release note:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I'm very pleased to announce the release of EMpy (Electromagnetic Python), a suite of numerical algorithms widely used in electromagnetism.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;The package, in its very-alpha stage by now, only contains the transfer matrix and the rigorous coupled wave analysis algorithms, and some handy functions and classes (to model materials, for examples). The idea is to expand it in the near future with new algorithms and interfaces to existent software. The package is based on Numpy/Scipy and its homepage: &lt;a href="http://empy.sourceforge.net/"&gt;&lt;a href="http://empy.sourceforge.net"&gt;http://empy.sourceforge.net&lt;/a&gt;&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Numerical computing Matlab vs Python + numpy + weave</title><link>https://lbolla-info.netlify.app/blog/numerical-computing-matlab-vs-python-+-numpy-+-weave/</link><pubDate>Wed, 11 Apr 2007 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/numerical-computing-matlab-vs-python-+-numpy-+-weave/</guid><description>&lt;p&gt;Recently, I've discovered the power of Python for numerical computing. Being a slave of Matlab for many years, I've decided to give Python (and it's numerical module &lt;code&gt;numpy&lt;/code&gt;) a try, comparing its number crunching capabilities versus Matlab's.&lt;/p&gt;
&lt;p&gt;The tests are heavily inspired by &lt;a href="http://www.scipy.org/PerformancePython"&gt;Prabhu Ramachandran&lt;/a&gt;. I've only added Matlab to complete his comparisons.&lt;/p&gt;
&lt;p&gt;Here is a short description of the test, taken from &lt;a href="http://www.scipy.org/PerformancePython"&gt;here&lt;/a&gt;:&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;The example we will consider is a very simple (read, trivial) case of solving the 2D Laplace equation using an iterative finite difference scheme (four point averaging, Gauss-Seidel or Gauss-Jordan). The formal specification of the problem is as follows.&lt;/p&gt;</description></item><item><title>Il Metodo</title><link>https://lbolla-info.netlify.app/blog/il-metodo/</link><pubDate>Wed, 14 Feb 2007 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/il-metodo/</guid><description>&lt;blockquote&gt;
&lt;p&gt;Il primo era di non prendere mai niente per vero, se non ciò che io avessi chiaramente riconosciuto come tale; ovvero, evitare accuratamente la fretta e il pregiudizio, e di non comprendere nel mio giudizio niente di più di quello che fosse presentato alla mia mente così chiaramente e distintamente da escludere ogni possibilità di dubbio.&lt;/p&gt;
&lt;p&gt;Il secondo, di dividere ognuna delle difficoltà sotto esame nel maggior numero di parti possibile, e per quanto fosse necessario per un'adeguata soluzione.&lt;/p&gt;</description></item><item><title>Google Docs</title><link>https://lbolla-info.netlify.app/blog/google-docs/</link><pubDate>Wed, 11 Oct 2006 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/google-docs/</guid><description>&lt;p&gt;Cool! Google has launched a new service, called &amp;quot;Google Docs&amp;amp;Spreadsheets&amp;quot;: &lt;a href="http://docs.google.com"&gt;http://docs.google.com&lt;/a&gt;. They are merging two different services already available (Writely and Spreadsheets) into one suite: at the very end, they are providing free a simplified online Office Suite.&lt;/p&gt;
&lt;p&gt;One nice feature is that you can post your docs on your blog in just few clicks. This post is the witness&amp;hellip;&lt;/p&gt;
&lt;p&gt;Wouldn't be nice to have just one &amp;quot;editor&amp;quot; on the web that any website can interface to? Just like Vi in &lt;code&gt;*nix&lt;/code&gt;? Pretty clever, though.&lt;/p&gt;</description></item><item><title>Maestro</title><link>https://lbolla-info.netlify.app/blog/maestro/</link><pubDate>Wed, 30 Aug 2006 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/maestro/</guid><description>&lt;p&gt;&lt;img src="http://www.artnet.com/artwork_images_89028_136123_Henri-Cartier-Bresson.jpg" alt=""&gt; Sometimes people find you.&lt;/p&gt;
&lt;p&gt;Sunday, I saw a documentary about &lt;a href="http://en.wikipedia.org/wiki/Cartier-bresson"&gt;Henri Cartier-Bresson&lt;/a&gt;. I must admit I had never heard about him: photography has never been an interest for me. But his photographs were mesmerizing. When, walking in the city center, thinking about decisive moments and how to picture them, I stopped in front of an exhibition. It was about photography. It was about Henri Cartier-Bresson.&lt;/p&gt;
&lt;p&gt;From never heard before, to be met twice in a day. Shouldn't we follow coincidences? I like his philosophy: photograph is like an instant painting. The most important thing is the instant: the &amp;quot;decisive moment&amp;quot;. Even if he was a reporter, he was convinced that reporting is not art. It's too much about informing. It's for everyone. Art is different, for few should like it. His photos &lt;a href="http://www.flickr.com/groups/thedecisivemoment-hcb/"&gt;inspired many people&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Ontologisches Beweis</title><link>https://lbolla-info.netlify.app/blog/ontologisches-beweis/</link><pubDate>Fri, 11 Aug 2006 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/ontologisches-beweis/</guid><description>&lt;pre tabindex="0"&gt;&lt;code&gt;Ass.1: P(φ).P(ψ) ⊃ P(φ.ψ)
Ass.2: P(φ) ∨ P(-φ)

Def.1: G(x) ≡ (φ)[P(φ) ⊃ φ(x)]
Def.2: φ Ess. x ≡ (ψ)[ψ(x) ⊃ N(y){φ(y) ⊃ ψ(y)]]

Ass.3a: P(φ) ⊃ NP(φ)
Ass.3b: ∼P(φ) ⊃ N∼P(φ)

Theo.1: G(x) ⊃ G Ess. x

Def.3: E(x) ≡ (φ)[φ Ess. x ⊃ N(∃x) φ(x)]

Ass.4: P(E)

Theo.2: G(x) ⊃ N(∃y)G(y)

Therefore:
(∃x)G(x) ⊃ N(∃y)G(y)
M(∃x)G(x) ⊃ MN(∃y)G(y)
M(∃x)G(x) ⊃ N(∃y)G(y)

Ass.5: P(φ).N(φ⊃ψ):⊃P(ψ) 
&lt;/code&gt;&lt;/pre&gt;&lt;ol&gt;
&lt;li&gt;Gödel, 1970&lt;/li&gt;
&lt;/ol&gt;</description></item><item><title>mi-vr-mi</title><link>https://lbolla-info.netlify.app/blog/mi-vr-mi/</link><pubDate>Sun, 14 May 2006 00:00:00 +0000</pubDate><guid>https://lbolla-info.netlify.app/blog/mi-vr-mi/</guid><description>&lt;p&gt;&lt;a href="http://static.flickr.com/56/146087373_8241e23cec.jpg?v=0"&gt;http://static.flickr.com/56/146087373_8241e23cec.jpg?v=0&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;First road trip by motorbike, this weekend: from Milan to Verona and back. You can see the photos &lt;a href="http://www.flickr.com/photos/lbolla/sets/72057594134326503/"&gt;here&lt;/a&gt;: one shot every 10 km, whatever there was&amp;hellip; (taken by my new camera! Lot's of news since the last time!)&lt;/p&gt;
&lt;p&gt;Motorbiking is relaxing and relaxing makes me think. So, while driving back home, I realized that there is a fundamental difference between motorcyclists and &amp;quot;car's drivers&amp;quot;: Solidarity. If a motorcyclist has a problem other motorcyclists stop to help him, if he is OK others keep greeting him. Can you imagine that with &amp;quot;car's drivers&amp;quot;? In Italy??&lt;/p&gt;</description></item></channel></rss>