Main page > Old news

Old news March 2007

2007-03-24 Blood Diamond

Added a review on Blood Diamond (in German).

2007-03-20 External oder site-specific search function?

Added a page which explains the pros and cons of search functions of Web sites and search engines (in German).

2007-03-12 M*A*S*H

Added a page on the TV show MASH.

2007-03-08 New recipe

I added a recipe for Zitronenquark.

2007-03-07 bc and exponentiation under Windows

I had a smaller problem getting something to work with the command line program GNU bc (basic calculator), version 1.05 compiled for Windows. I had only used it in the past for very simple terms with multiplication and addition. When using the exponentiation operator ^ in an expression, it never seemed to arrive when piping the expression to bc with echo like that: echo 2^3 | bc yields 23 instead of 8. The ^ character seems to get lost. Indeed, it has to be escaped for the NT-based prompt cmd.exe by doubling it—twice, once for echo and once for the piping. So echo 2^^^^3 | bc yields the correct result 8.

I was also using division for the first time, and bc by default seems to round to the nearest integer. In order to get higher precision, the amount of digits must be specified via the scale variable:

echo scale=10;(2^^^^62-2^^^^^31+1)/(2^^^^60) | bc
3.9999999981

This is the number of exabytes for the term 262-231+1 rounded to ten digits.

This just as a note for future reference, primarily for myself, maybe it also helps someone else.

2007-03-06 Lines that are in one text file, but not the other

After I once again had to reinvent some command line I had figured out a while ago, I've decided to start collecting these things here. Only the ones that have at least a small chance of being useful for someone else, so this one's not the command that was difficult.

If you have two sorted text files a.txt and b.txt and want to find out which lines from b.txt are missing in a.txt, use the Unix utility join like that:

join a.txt b.txt -v 2

It will only print those missing lines.

2007-03-05 Another short review: Trennung mit Hindernissen

Trennung mit Hindernissen (The Break-Up).

2007-03-01 Movie reviews

I added several smaller movie reviews: