Xah Programing Blog Archive 2013-01

learned that the ⌘ command key and ❖ Window are really identical in keyboard hardware. They send out the same scancode. Similarly, ⌥ option and Alt are identical. Updated: Difference Between Apple and Microsoft keyboards

updated:

try ErgoEmacs!

breaking news from the emacs department. Even if you are not a emacs user, this might be interesting.

ErgoEmacs version 2.0 release candidate is out. http://code.google.com/p/ergoemacs/downloads/list

ErgoEmacs is a emacs with modernish interface, meaning, the keys for common commands such as open, close, save, copy, cut, paste, select all, are the same for any app on {Microsoft Windows, Mac OS X, Linux}

so, this means, you can use emacs right away, while, explore the power you constantly hear elite hackers talk about. Give it a shot.

much thanks to the Window programing guru David Capello (David wrote wrote many apps for Microsoft Windows, the most popular is probably the pixel editor aseprite http://www.aseprite.org/ check it out.)

Unicode Symbol for “e.g.” (exempli gratia)

spat with the redoubtable lisper, computer scientist Richard Fateman. Systematic Syntax: Lisp vs Mathematica

my linux question. Linux: Update Software by Command Line

Python Scope Complexity, Shallow Copy, Deep Copy, Circular List, and the Garbage Underneath Computer Languages

updated. Unison Tutorial (Sync Files)

note that Unison is written in OCaml [see OCaml Tutorial].

Updated. AutoHotkey Example Scripts

for much more on keys and tools, see latest at Xah Emacs Blog

updated: Windows: Best Anti-virus Software

on its own page. XML Syntax is Inferior Lisp Syntax?

new. Ruby: Quote Long String, Heredoc

I'm now a avid fan of the Truly Ergonomic Keyboard .

Philosophy Keybinding Efficiency: Home/End, Page Up/Down, and Key Chords

new. Learn Perl in 1 Hour. A bit rough, but i gotta start somewhere.

make the number keypad useful!

if you use a full keyboard with number pad, you should use it for function keys. Indispensible.

if you often work on laptop, then, i recommend F11 F12 for prev/next tab, and F10 for close. (Ctrl+Shift+t un-close last closed, in Firefox, Google Chrome.)

rid of any key combos.

and, within emacs, you can easily set keys too. F11 F12 for prev/next user buffer, and F10 for close current buffer. (the commands are in ergoemacs-mode)

“recursion” — a central theme in this song. Björk — Bachelorette

here's recursion bonanza.

On the news, that there's a new zero-day exploit of Java. How to Disable {Java, JavaScript, Flash} in Web Browsers

What is a zero-day exploit?

software defects that are vulnerable to hacking or virus attacks are sensitive to whether they are exposed to public for the first time. Because, once a virus or hack exploited that defect, companies or software experts will respond to it and more than likely to fix it. So, this means, the first time a virus or defect are exploited, it's the most damage done, that's Zero-day exploit.

coded this interview problem. Luhn Algorithm

old article, still relevant: Why Must Software be Rewritten for Multi-Core Processors?

Aaron Swartz (of Reddit fame) killed himself yesterday.

Aaron's mom comment on Hacker News at http://news.ycombinator.com/item?id=5047398

discussion of Aaron's death on Hacker News http://news.ycombinator.com/item?id=5046845

Unicode Icons for Food and Drink

Unicode: Food Emoji 🍺

On my Microsoft Windows 7 machine, only Firefox display them well (missing just 2 characters).

All other browsers, Google Chrome, Safari, Opera, Internet Explorer 9, got nothing.

I do have Unicode 6 fonts installed (Symbola, Segoe UI Symbol). Somehow these browsers are not picking it up. [see Best Unicode Fonts for Programer] [see Unicode 6 Emoticons and Supporting Fonts]

On Linux, default setup of Ubuntu 12.04, none of them shows up in Firefox.

What is your experience? (tell me your OS, browser, their versions, and whether you have installed special fonts yourself.)

Python script to generate thumbnails from inline image links in HTML files. https://github.com/xahlee/xah_generate_thumbnail

A personal script. Now dumping to github.

The script is used to generate thumbnails for my gallery pages, example

Second Life, the Worst Hack in Universe

A Perl lib that emulates 30 list/tree manipulation functions in Mathematica. Tree::Matica Perl module

been thinking of reviving the project and port it to Python, Ruby. You are welcome to do so!

What Happens When You Name Your Functions/Variables as Math Symbols? See new section at bottom: Variable Naming: English Words Considered Harmful (programing practice; computer language design)

Windows CLSID GUID UUID

Lisp-1 vs Lisp-2

Why Python Lambda is Broken and Can't be Fixed

a new poem, for Ruby!

there is a Python, pithy
mighty, lissome, and tabby
algorithms it puffs
conundrums it snuffs
and cherished by those savvy

there is a camel, kooky
ugly, loathsome, ungainly
hacking it supports
TIMTOWTDI it sports
and transports DWIM-wit's fancy

there is a gem, named Ruby
simply shiny and pretty
objectively beautiful
functionally magical
code a web of Rails happy

Ruby Tutorial

Recently updated: linux man page tips: Linux: man page Tutorial

new: Ruby: Predefined Variables

See the bottom of the file for some Ruby quirks.

Ruby's predefined var is similar to Perl. In Perl, you can see the doc of them all by perldoc perlvar. But for Ruby, i haven't been able to find doc of these. Looks like it's not really documented.

Added Ruby.

Intro to Reading Ruby Doc: What's M, C, ::, # ?