1 Broken Scooter, 4 Iron Cots, 1 Used Ford, 3 Cats, and 1 Small Room


About
Yet Another Self-Important Blog.



Rohit Singh
Email Me



Blogs
Use as directed or at your own risk.



Links
These are a few of my favourite links.




       

[Thu, 26 Feb 2004]

Unicode coding

Da dude is yapping about some unicode stuff he did at work. Reminded me of my own non-encounter with unicode during job. Me being the data formats guy, my team-lead bounced off a bug-report about a file that could not be opened. Apparently, this particular data format had the file name copied *inside* the file (don't ask why!). Just before that field, there was a field that mentioned how long the next field (file-name) was. And the two didn't agree i.e. the file's name was shorter than it was supposed to be.

This bug had come from a Japanese sales guy who was in total panic over some big deal that depended on fixing this bug. Now, almost all of the file seemed to be in ASCII text-- it was mostly DNA sequence data only. But the file name wasn't! It was a Japanese file name, written in Unicode. Each unicode letter is 2 bytes. ASCII, with 128 chars, is only 1 byte and one bit is still left empty. The short story is that the program was confusing the higher order unicode byte for the null character and terminating the string-read.

The right way would have been to fix all our code to use Unicode libraries so as to read these things even if they were written in Egyptian Hierloglyphs. In addition to this being damn tedious, we'd have lost the sale and it wouldn't be fun listening to a Jap swearing in English. I did what my boss recommended- skip reading the file-name from inside the file. The damn thing is already known.

[/misc] permanent link

(Re)Heating Tortillas

Tortillas, as compared to rotis, inspire the same feeling in Indians that Canada inspires in Americans- "almost like us, but just a bit weird". Tortillas are too big, a bit too rubbery, have too much oil, and are too un-fluff-able for roti aficionados. At the same time, they are made of wheat, are thin and round, look quite similar to rotis and are far closer to rotis than any other species of normally available bakery products. Therein lies the dillemma.

The biggest problem with tortillas is heating them. Any self-respecting roti is warm, soft, and a bit fluffed up. With tortillas, however, getting both the "warm" and the "soft" part is tricky. Forget about the "fluffed-up" part. Microwaves, unfortunately, make hot papad out of tortilla. As it is, frozen tortilla already has some papad like tendencies. Even heating it on a tawa doesn't usually get rid of the frozen chip-like parts. The worst part is, a heated tortilla has to be eaten immediately. As it cools, it hardens. So the 2nd tortilla on your plate is already a papad by the time you get to it. Another option is to use more oil and make parathas out of tortillas, since hardened parathas are not as bad as hardened rotis. However, its just not the same thing.

Today, I tried something. I let the frozen tortilla, from the fridge, sit in water for about 15 secs. The resulting thing seems like it is barely hanging on to itself and will decompose into dough any minute. I then transferred it to the hot tawa/pan. Here's the important part: You have to use tongs or something to flip the thing very frequently (every few seconds) otherwise the wet stuff sticks to the pan. But if you manage to do the flipping well and wait until some brown spots appear, you have a warm and soft tortilla (with a nice paratha-like sheen) that stays soft for quite a while.

[/misc] permanent link