Random knowledge IV.

Mar 17, 2016

Just because it's usually the one-half teaspoon that falls off the holder and it's usually the one-half teaspoon that fell off the holder that you grabbed out of the drawer doesnt't mean that it's the one-half teaspoon that you really grabbed. Always look before you use measuring implements.

When a recipe says to use eggs, use real eggs. Four times out of five, Egg Beaters just won't cut it.

When creaming butter and sugar together (probably butter and anything, I havn't tried yet) it doesn't hurt if you melt the butter in a skillet or frying pan first. If anything it makes it easier, plus it doesn't make for little chunks that go flying everywhere when you crank up the electric mixer.

If more than one person is working on hooking up a subwoofer of some sort, make sure that the person actually working on the speaker itself is touching it with only their hands and arms. If any part of the head is resting against the speaker housing if and when the speaker comes on line (if there's already sound going through the PA system) they're going to get their bell rung but good on the first firing. Earplugs just aren't going to help when the shock wave is travelling through the bones of the skull and not the open air.

Alternately, the person not working on the speaker itself should give the other person a ten second warning after saying "Okay, let's try this.."

We were all newbies, once.

When programming in C++, arrays may be created dynamically by attaching them to a pointer of the appropriate type, like this:

int *dynamic_array;
dynamic_array = new int[1024];

The new dynamic array may then be accessed like any other array. When you're finished with it, however, you must deallocate the array using the delete command. Moreover, you must deallocate the entire array and not just a single cell of the array. You'll want to do this...

free [] dynamic_array;

..and not this:

free dynamic_array;

If you don't, your programme will leak memory and probably die from a segfault.

To get printing working under Mozilla for *nix, set the environment variable $MOZ_PRINTER_NAME to the name of the print queue you want to use (found in /etc/printcap) - I use 'aps1' for my Canon BJC-2100 printer. Then log out and log back in. Run Mozilla and give it a try.

While you're at it, set the environment variable $PRINTER to the name of your preferred print queue as well. That way you don't have to keep using the -P option with the lpr utility. This also seems to get printing working in Staroffice from Sun Microsystems (I just did it now) but without deliberately trying I really don't know yet.

I don't care how simple the system is or how much you use it - whenever you install a new version of something, never erase the old version until you're sure the new one's working. Read the bloody release notes, they're there to tell you what's changed and what you have to set up first to get it all working. And for Kibo's sake, read the freaking manual so you know how to use the new features.

There are some people in thie universe who, for whatever reason beyond human ken, were never meant to be lovers.

If you think you've really screwed up your USB-interfaced printer, make sure that you're actually working with the cable leading to the printer and not something else, like the external CD-RW drive. It's easy to get confused and think you're plugging in the right device when you're really not. Don't waste a reboot when you can physically trace a cable from jack to jack.

To print whatever you happen to be editing in vim (Vi IMproved) at the moment, enter the command ':hardcopy' to dump it to your default printer (usually set in the $PRINTER environment variable).