Monday, October 31, 2005

illustration of qsort using Microsoft Visual C++

/* illustration of the C library function qsort();

qsort() is a very efficient implementation of the Quicksort
(actually Quickersort) algorithm;

the C library function allows sorting of nonnumerical objects,
so the user must supply his/her own comparison function, which
defines whether one object is "smaller" than another;

in our example here, an "object" will be a character string;
one string is considered "less than" an other if the first
string would come before the second if they were listed in a
dictionary (so this is called "lexicographic ordering," from
the word "lexicon," which means "dictionary")

this comparison can be done by the C library function strcmp(),
but here we wish to make no distinction between lower- and
upper-case letters, so we cannot use strcmp(); thus we are
providing our own function instead, MyStrcmp()

the compare-function has two arguments, which are the addresses
of the two items to be compared, and returns an integer value
which is either less than 0 (signifying that the first object
is "less than" the second), equal to 0 (signifying that the
two objects are equal) or greater than 0 (signifying that the
first object is greater than the second */

#include <stdafx.h>
#include <string.h>
#include <stdlib.h>

#define MaxNWords 100
#define MaxWordLength 20


char Word[MaxNWords][MaxWordLength]; /* array of words to be sorted */


int MyOwnStrcmp(char *WordPtrA, char *WordPtrB)


{ char LCWord[2][MaxWordLength],C;
int UpperVsLowerDiff,I,J;

/* first, make copies of the two input strings, except that in
the copies all upper-case letters have been changed to lower-
case */
strcpy(LCWord[0],WordPtrA);
strcpy(LCWord[1],WordPtrB);
UpperVsLowerDiff = 'a' - 'A';
for (I = 0; I < 2; I++)
for (J = 0; J < MaxWordLength; J++) {
C = LCWord[I][J];
if (C >= 'A' && C <= 'Z')
LCWord[I][J] += UpperVsLowerDiff;
}

/* OK, now we can use the ordinary strcmp() function */
return strcmp(LCWord[0],LCWord[1]);
}


void main()

{ int I,NWords;

printf("enter words, with ctrl-d to end\n");
for (NWords = 0; ; NWords++) {

scanf("%s",Word[NWords]);

if (strcmp(Word[NWords],"mike") == 0) break;
}

/* qsort()'s parameters are:
address of the first object
number of objects
sizeof(object)
name of the compare-function */
//qsort(Word,NWords,MaxWordLength, ((int *)()) &MyOwnStrcmp);


///typedef (int *ccc)(void *, void *);
// typedef int (*c)(void *, void *);


qsort(Word,NWords,MaxWordLength, (int ( * )(const void *, const void *)) MyOwnStrcmp);

// qsort(
printf("\n\nsorted array:\n");
for (I = 0; I < NWords; I++) printf("%s\n",Word[I]);

fflush(stdin);
getchar();
}

shortest code for quick sort

#include <stdafx.h>

int A[] = { 99, 43, 22, 17, 57, 32, 43, 19, 26, 48, 87, 12, 75, 0 };
const int numEntries = sizeof(A)/sizeof(int);
void quicksort (int a[], int lo, int hi)
{

// lo is the lower index, hi is the upper index
// of the region of array a that is to be sorted
int i=lo, j=hi, h;
int x=a[(lo+hi)/2];

// printf("\npivot:%d",x);

// partition
do
{
while (a[i]<x) i++;
while (a[j]>x) j--;
if (i<=j)
{
h=a[i]; a[i]=a[j]; a[j]=h;
i++; j--;
}
} while (i<=j);

// recursion
if (lo<j) quicksort(a, lo, j);
if (i<hi) quicksort(a, i, hi);
}


void qksort() {
quicksort(A,0,numEntries - 1);
}

void printArray(void) {
for (int i = 0; i < numEntries; i++) {
printf(" %d\n", A[i]);
}
printf("\n");
}




int main(void) {
printf("Before sorting, the entries of A are:\n");
printArray();
qksort();
printf("After sorting, the entries of A are:\n");
printArray();
getchar();
}


/*


Before sorting, the entries of A are:
99 43 22 17 57 32 43 19 26 48 87 12 75 0
After sorting, the entries of A are:
0 12 17 19 22 26 32 43 43 48 57 75 87 99


*/

Wired News: Infrared Detects Sniper Gunfire: "WASHINGTON -- A sniper fires on American troops in Iraq. In the milliseconds before the bullet hits -- in fact, before the shot is even heard -- a computer screen reveals the gun's model and exact location. That's the kind of intelligence that can save soldiers' lives. The Army is currently testing the technology in combat."

online payment

attention www.bancnetonline.com.ph and pldt.com.ph

bakit walang payment options for pldt?

smart meron
meralco meron
mwss meron
pldt wala, bkit globe meron?

mag-globe dsl n lng kaya ako

Sunday, October 30, 2005

RP an attractive offshore destination, but not for IT - INQ7.net: "THE PHILIPPINES now ranks second in the world’s top 14 destinations for business process outsourcing (BPO), next to India. However, the country ranks poorly when it comes to information technology outsourcing (ITO), a recent study by NeoIT shows.

In its recent Mapping Offshore Markets Update 2005, NeoIT (www.neoIT.com) indicated that the Philippines remains a contender in the global offshore BPO market. The Philippine offshore BPO market size is estimated to be about 800 million dollars in 2004. India's offshore BPO market size is worth 5.2 billion dollars in the same year.

The Philippines' IT outsourcing market size, on the other end, is about 330 million dollars in 2004, measly compared to India's 12.2 billion dollars, the study noted.
"

Thursday, October 27, 2005

Mind & Body - Brought to you by INQ7.net:

Binge on broccoli to
boost the brain

By Agence France-Presse


LONDON--Eating certain fruit and vegetables could boost the memory, particularly broccoli, according to British research.

The research provides scientific backing to the theory and has major implications for the prevention and treatment of Alzheimer's disease, the Royal Pharmaceutical Society said.

Extracts found in five fruits and vegetables -- broccoli, potatoes, oranges, apples and radishes -- were found to contain substances that act in the same way as drugs used to treat the disease. Broccoli had the most.

The study by King's College London, part of the University of London, was to be presented on Tuesday at the British Pharmaceutical Conference in Manchester, northern England.

Alzheimer's, for which there is no cure, is the most common form of dementia among older people. It seriously affects their ability to carry out daily activities, impairing parts of the brain that control thought, memory and language.

Most of the drugs used to treat the disease act as inhibitors of acetylcholinesterase, the enzyme responsible for the breakdown of the neurotransmitter acetylcholine.

It has been previously suggested that some common vegetables might have anti-acetylcholinesterase activity, but no detailed investigation has ever been carried out. The King's College London research confirms this activity in all five of the fruit and vegetables.

Broccoli was found to have the most potent activity and was taken forward for further tests to identify the agent responsible.

These were found to be glucosinolates, a group of compounds found throughout the cabbage family.

"As yet, it is unproven that eating broccoli, for instance, would have a beneficial effect on Alzheimer's disease," said professor Peter Houghton, from King's College London.

"But the long-term effects of regularly consuming these compounds in vegetables belonging to the brassicaceae (cabbage family) might certainly be beneficial in reducing a decline in acetylcholine levels in the central nervous system."

"This is the first report that glucosinolates have acetylcholinesterase inhibitory properties."

Wednesday, October 26, 2005

Memory Upgrades for PC or MAC from Data Memory Systems: "HOW DO I KNOW IF I NEED PARITY, NON-PARITY, OR ECC, NON-ECC MEMORY?

The general rule of thumb in deciding what type of memory you need is to look at what’s already installed in your system. To find out if you have ECC, parity, or non-ECC, non-parity memory, count the number of chips on the module. Divide the total number of chips by three. If you can evenly divide the number of chips by three, the module is ECC or parity, if not, then it is a non-ECC, non-parity module. If you're building a PC and plan to use your system as a server or a similar mission critical type machine, it is to your advantage to use ECC. If you plan to use your PC for regular home, office, or gaming application, you are better off with non-ECC, non-parity memory.

HOW TO TELL ECC, PARITY MEMORY FROM NON-ECC, NON- PARITY MEMORY?

If your system has ECC or parity memory the chips are evenly divisible by three. How do you know which one you have? One way is to look at the part numbers on the chips of your module. If each chip has the same part number, you have ECC. If one chip is different, you have parity.

WHAT IS THE PERFORMANCE DIFFERENCE BETWEEN ECC, PARITY AND NON-ECC, NON-PARITY?

ECC (error checking and correcting) memory performs double bit detection and single bit correction. This means that if you have a single bit memory error, the chipset and memory will find and repair the error on the fly without you knowing that it happened. If you have a double bit memory error, it will detect and report it. Non-ECC, non-parity memory, on the other hand, has no error detection and correction capabilities.
Using ECC decreases your PC’s performance by about 2%. Current technology DRAM is very stable and memory errors are rare, so unless you have a need for ECC, you are better served with non-ECC, non-parity memory."

What's In Store for 7-Eleven?: "The Japanese influence is palpable in 7-Eleven's information technology. The Dallas-based company is widely viewed as a technology leader, not only among convenience stores but all retailers. That's because 7-Eleven managers in the U.S. can track sales at their 5,300 stores item-by-item, hour-by-hour with one-of-a-kind software hand-coded by programmers in the mid-1990s.

7-Eleven's retail-information system, or RIS, as the company calls it, was built to fulfill Ito-Yokado's philosophy that successful retailers 'hypothesize, take action, then verify.'"

Sunday, October 23, 2005

MySQL vs. PostgreSQL: "Many readers responded to mysql / microsoft tax post by asking why I hadn't considered postgreSQL as an RDBMS platform. The reason for this is simple: when it comes to infrastructure software (like an rdbms), I'm a mainstream buyer, not an early adopter. What mainstream buyers do is base their behavior on other buyers, relying on the market to make the decision for them."

Saturday, October 22, 2005

Slashdot | Why Have PDAs Failed In The iPod Era?: "In the case of a PDA, the spirit just isn't there; a PDA is a catchall device. In a lot of minds, 'a solution looking for a problem'."

Friday, October 21, 2005

Behaviour - Intelligence and Language: "Dolphins have a language to communicate with one another. It differs a lot from that of humans.

For an example, we use facial expressions as a way of communicating. When we are angry, this can be read from our facial or body expressions like clenching fists or frowning. When we are happy we smile, and sometimes we will raise our hands to show extreme happiness.

Dolphins cannot do all these. They can't make facial expressions and they can't do many actions with its body. The spoken language is another thing which dolphins can't use. They don't have vocal chords and the only body part that can create any sound is the blowhole. This makes it very difficult to communicate with one another. Researchers have tried deciphering the sounds of dolphins but nothing really significant has come out of their research.

Another example of a shaky communication is between the dog and the cat. They have the same ways of communicating but not the same language. When for example the dog wags its tail, it means that it is happy. When the cat uses this same signal, it is an indication of hostility. This is the reason that the communication between a dog and a cat falters.

There are two causes for bad communication. Firstly it is the different ways of communicating and secondly the different language. For the communication between people and dolphins, both factors clash. In the first case it is the different communicational methods which cause the clash. Secondly, it is the constant facial expression of dolphins and the incomprehensible sounds that a dolphin produces, of which humans can decipher almost nothing.

The only communication that exists is the movements that we make. This is very helpful in dolphinariums. When an attender turns, the dolphin has to follow. When the attender claps his hands, the dolphin will perform another trick. This is the only effective way of communication so far."

Thursday, October 20, 2005

PostgreSQL General Bits: "You can create and use temporary tables inside of pl/pgsql functions, however, there is a catch. pl/pgsql functions are parsed when they are first run. Subsequent calls use the same query structures to run. If one of those queries accesses a temporary table created and dropped in the function it will work the first time, but not the second. The second time it is called, it will still be trying to access the first invocation's temporary table, not the newly created one.

The workaround/proper way to handle this situation is to perform queries which access temporary tables in plpgsql functions by using EXECUTE. By using EXECUTE, the query is reparsed and the proper (new) temp table is accessed.

-- This will not work
...
CREATE TEMP TABLE foo AS SELECT ....;
FOR r IN SELECT * FROM foo
LOOP
....
END LOOP;
DROP TABLE foo;

-- This will work
...
CREATE TEMP TABLE foo AS SELECT ....;
FOR r IN EXECUTE 'SELECT * FROM foo'
LOOP
....
END LOOP;
DROP TABLE foo;
..."

The Opening of the Field: PostgreSQL's Multi-Version Concurrency Control LG #68:

A Deeper Look at MVCC

Database systems that use row-level locking do not retain old versions of the data, hence the need for locks to maintain data consistency. But a deeper look into how "no-locking" through MVCC works in PostgreSQL reveals how PostrgreSQL gets around this limitation. Each row in PostgreSQL has two transaction IDs. It has a creation transaction ID for the transaction that created the row, and an expiration transaction ID for the transaction that expired the row. When someone performs an UPDATE, PostgreSQL creates a new row and expires the old one. It's the same row, but in different versions. Unlike database systems that don't hold on to the old version, when PostgreSQL creates a new version of the row it also retains the old or expired version. (Note: Old versions are retained until a process called VACUUM is run on the database.)

That's how PostgreSQL creates versions of the data, but how does it know which version to display? It bases its display on several criteria. At the start of a query, PostgreSQL records two things: 1) the current transaction ID and 2) all in-process transaction IDs. When someone accesses data, Postgres issues a query to display all the row versions that match the following criteria: the row's creation transaction ID is a committed transaction and is less than the current transaction counter, and the row lacks an expiration transaction ID or its expiration transaction ID was in process at query start.

And this is where MVCC's power resides. It enables PostgreSQL to keep track of transaction IDs to determine the version of the data, and thereby avoid having to issue any locks. It's a very logical and efficient way of handling transactions. New PostgreSQL users are often pleasantly surprise by the performance boost of MVCC over row-level locking, especially in a large multi-user environment.

MVCC also offers another advantage: hot backups. Many other databases require users to shutdown the database or lock all tables to get a consistent snapshot - not so with PostgreSQL. MVCC allows PostgreSQL to make a full database backup while the database is live. It simply takes a snapshot of the entire database at a point in time and dumps the output even while data is being inserted, updated or deleted.

CONCLUSION

MVCC ensures that readers never wait for writers and writers never wait for readers. It is a logical and efficient version management mechanism that delivers better database performance than traditional row-level locking.

The Great LAN Shop RAID -- Pinoy Tech Blog - The Philippines’ Premier Technology Blog: "Kates » September 21st, 2005 05:50
8

@Clair:
In that case, that’s good news. Gov’t offices shouldn’t be exempted.

Should I start printing a “Linux Consultant” business card? :)

@Rain:
May bagong pagka kitaan ka na. Linux troubleshooter ng mga cafe. I’m sure they are in dire need of a good linux tech support."

Slashdot | Cell Phones Learn to Recognize Their Owners' Faces: "Cost of failure is too low to justify this
(Score:5, Interesting)
by Anonymous Cowdog (154277) on Thursday October 20, @12:14AM (#13833039)
(Last Journal: Tuesday November 16, @02:29AM)
I think they are treating the phone a little too much like a gun.

It's not like it will be the end of the world if someone can access my personal phone information. I can control what I store on there; it's my own choice whether to put private things in a phone, and while the list of people I call is private, it's really not that big of a deal. And there are other ways of remotely restricting access.

Seems like a case of some technologists with a hammer, looking for a nail."

Friday, October 14, 2005

Ape Culture - The Beatle Personality Test:

Disclaimers

TBPT can not be responsible for gross or reckless misuse of Beatle Typing. Please proceed with caution and a healthy sense of reality, if you’ve got one handy. As Typewatchers remind us, your Beatle strengths unchecked become a Beatle liability. Remember: The Beatles broke up!

I am sure there are complexities in each of the Lennon/McCartney personalities and within their relationship. For the purposes of this test, I am going to assume that there are not.



The McCartney Type (PMT)

* Social
* A vaudevillian extravert ("Say Say Say" the video)
* Has extensive Work (more solo lps…death is no excuse for Lennon. Elvis is dead and he is still releasing lps )
* High energy expenditure ("Band on the Run")
* Deals in the present ("Let It Be")
* Realistic, Factual, Practical ("Baby I’m Amazed",
"With a Little Luck")
* Believes in perspiration ("The Long and Winding Road")
* Down to Earth ("Silly Love Songs")
* Specifics ("Uncle Albert", "Junior’s Farm")
* Laws, policy, clarity ("Live and Let Die")
* Detached (no bed-ins)
* Decided, fixed (Paul Is Live)
* Needs control, plans ("No More Lonely Nights")
* Structure, schedule (Liverpool Oratorio)
* Marries wife who works in reality based art: photography

A Paul McCartney Fan Page


The John Lennon Type (TJLT)

* Opinionated, self-righteous (can you tell which type I am?)
* Introvert (Mind Games)
* Energy conservation (peppy is not cool)
* Reflective ("Ballad of John & Yoko")
* Random inspiration ("Strawberry Fields Forever")
* Deals in the future ("War Is Over")
* Conceptual, theoretical (The Plastic Ono Band, "Imagine")
* Head in the Clouds ("Lucy in the Sky with Diamonds")
* Fantasy world (Double Fantasy)
* Involved, social values ("Revolution")
* Flexible, adaptable (to Yoko)
* Open ended (Somewhere in New York City)
* Verbally brave ("We’re bigger than Jesus")
* Marries wife who works in abstract based art

Slashdot | Deciphering the Brain's Love Map: "'Most people fall in love because they have shared values, but they stay in love because their personalities mesh'

Hmm. Sounds like a weenie in marketing came up with that. Wonder how long it is until he gets his own daytime TV show, or a website like that wiener with his Men are from Mercury and Women are from Uranus [marsvenus.com] or whatever...

Someone once wisely said that compatibility is really about adaptability. People go into relationships expecting 'compatibility'. What people really need to do is learn how to adapt to other's personalities. Even if you have met someone with whom you are compatible you will have to constantly adjust your personality so that you can stay in tune with this person. People do change after all.

Also, if people do not have a sense of commitment things will fall apart once times get tough. Our society in general looks down on commitment as being old fashioned. Maybe that's why our divorce rate is 50%. Chemistry.com won't change that and I have to suspect will go the way of webvan.com."

» If AMD is David and Intel is Goliath, What is VIA? Cinderella? | Between the Lines | ZDNet.com: "Kowal, a native of Canada now living in Taiwan where VIA is headquartered, is touring the US to talk about the latest addition to VIA's processor lineup — the C7-M. The 'M' stands for mobile and, according to VIA, this processor is, watt-for-watt, the most powerful processor on the market (although it could be true, I can't verify this since no systems are shipping yet). What's so special about the C7-M? It's a 2 GHz x86-compatible processor that, according to Kowal, not only takes only 20 watts of power (Intel's latest Pentium M takes 27 and AMD's most advanced Turion, which is 64-bit capable, takes 25) but also has a built-in security co-processor that can perform AES encryption on data being transmitted across the network or stored locally on the hard drive in real time."

Kriston.net -- Software Engineer, Systems Administrator, Hardware Technician, Developer, Development, Sysadmin, C, C++, Java, Tcl, Security, Encryption, VoIP, Telephony, Linux, Solaris, Unix, Windows, Servers, AOL, IBM, Kriston Rehberg: "It runs very well without a CPU fan, too, making it the perfect bedroom computer."

hardCOREware.net - Hardware Reviews for HARDCORE Gamers!: "Although nothing drastic, some changes have been maded to the ATX spec to accomodate these new platforms, particularly the insane video cards that take upwards of 75W when under full load..."

Thursday, October 13, 2005

JavaScript Form Validations Made Easy!

Wednesday, October 12, 2005

The Seattle Times: Business & Technology: Microsoft sees a future on the small screen: "Series of grand schemes

Talk of a Microsoft TV platform may seem like déjà vu. Over the years, the company has unveiled one grand scheme after another to provide TV services.

It first tried to merge the PC and the TV with a ballyhooed system called Tiger that it announced with Intel in 1994. Oracle and other competitors scoffed that Microsoft didn't have the experience to deliver such a system. It couldn't even get the prototypes to work when Chairman Bill Gates demonstrated them to a utility association in Seattle.

'You can see it's not going to happen overnight,' Gates said at the time.

Then the company spent years developing sophisticated cable boxes. It also bought a California company called WebTV, which made devices for surfing the Web on a television, and continues to offer that service as MSN TV.

Partly to open doors with potential customers, the company invested more than $10 billion in phone and cable companies, including a $5 billion investment in AT&T, which later merged with Comcast. But that did little to move its early TV products.

Microsoft's cable boxes were ahead of their time. After cable operators scaled down plans after the tech bubble burst, the boxes lost potential customers. So far they're being used only by Comcast in the greater Seattle area and by three companies in Mexico."

Crawdaddy Interview with George Harrison 2/77: "GEORGE: 'That's good-- I like that. I think individual love is just a little of universal love. The ultimate love, the universal love or love of God, is a basic goal. Each one of us must manifest our individual love, manfest the divinity which is in us. All individual love between one person loving another, or loving this that or the other, is all small parts or small examples of that one universal love. It's all God, I mean if you can handle the word 'God.''

'Ultimately the love can become so big that we can love the whole of creation instead of 'I love this but I don't like that.' Singing to the Lord or an individual is, in way, the same. I've done that consciously in some songs.'

'I've had alot of interest in different ways and one of the things I never liked was the whole bit in the late '60s when everybody started getting into it. One thing I really disliked was this, 'My guru's better than your guru.' It's like little kids on the street-- 'My dad's bigger than your dad.' The point is that there is only one God, he's got millions of names, but there's only, but there's only one God. "

Tuesday, October 11, 2005

Data Points: Migrating from ADO to ADO.NET, Part 2 -- MSDN Magazine, August 2004: "Migrating from ADO to ADO.NET, Part 2"

Saturday, October 08, 2005

Slashdot | Switching to Contracting?: "1) First, take base pay (P), and multiply by 2/3rds.

2) Then, take out at least 10% for 'short term' savings (S) - in case you lose the job (something like a savings account would do.) If this acct ever gets over a couple thousand, move it to long-term savings.

3) Then, take out another 10-20% and set that side for retirement (R) in a long-term fund. I set it this high for several reasons: 1) you want to retire early, 2) inflation, 3) knowing the flukes of our economy and career choice, you'll likely need it sooner than later. This is also a practice of the Japanese culture (or was, 10 years ago), and it's been shown that the 'recommended' 10% that most Americans save has traditionally not been enough.

4) Now, figure what your annual health (etc.) costs (H) will be, and subtract it from what you have left.

5) This will leave you with the money you have for day to day annual living. Divide by 52 to figure out what your weekly available budget would be.

6) Figure out what you could get by on in order to pay rent/mortgage, food, utilities and a base level of entertainment (eating out, movies, video games) funds for the both of you. Subtract this living cost (L) from the total.

7) You should have at least 5% of your living costs left over at the end of the month.

So, in summary:

((2/3)P - SP - RP - H)/52 - L >= 0.05(L)"

Slashdot | Switching to Contracting?: "There's a saying -- going freelance is trading the illusion of job security for the illusion of freedom.

In any case, what I really enjoy about freelancing is that it's very easy to take multiple clients and combine a lot of your overhead to reduce/write off costs.

Also, with multiple income streams, you can effectively eliminate the one client who is starting to become a nuisance without threatening your way of life too badly.

Summer's coming along? Drop down to one client and take it easy. Need extra cash? Work like a dog and see the results in your bottom line.

Pinch pennies for a year and you've got a comfortable cash cushion that'll smoothen out most unexpected employment mishaps.

Requires a strong can-do attitude and self-control.

It was a bit scary at first, but once I started believing in myself, getting the work became pretty easy and I'm generally a much happier person now that I made the step.

At this point, you'd have to kill me before I would agree to work a fixed 40 hour/week schedule."

Slashdot | Switching to Contracting?: "So all in all - You do need insurance if you are married because if either gets sick its on the other's shoulders. Contracting is a good way to go - just make sure you do a really good job because your tenure is a 5 minute phone call.

As for steady employment? Well - I had to interview and hire my supervisor - but made 2x his salary. I didn't think that was a bad idea and I was able to STAY COMPLETELY AWAY from all office politics... everyone knew I was not after anyone's job!!!

The life of a contractor can be bliss."

Friday, October 07, 2005

CRT vs. LCD Monitors: Which Monitor is the Best to Buy?: "Finally, the color clarity of CRT monitors cannot be matched by an LCD screen. With the myriad of adjustments that can be made to the contrast, brightness and hues, CRT monitors are better able to represent actual document colors. This is extremely important for individuals who work in either print or graphics industries. Having an accurate reproduction of the color of a document on the screen when it is printed can save a huge amount of hassle when it comes time to have documents published.

Of course, all these advantages do have their drawbacks as well. The biggest drawback to CRT monitors is their bulkiness. The tubes within the CRT monitors are extremely heavy. This is primarily necessary for safety reasons. The tube is a vacuum and if it were to crack, the monitor tube would implode. The tubes also draw a large amount of power. Some larger CRT monitors now can actually draw more current than the computer they are attached to. The visible area of the tube is also smaller than the actual tube size. When a company markets a 19' CRT monitor, the actual visible area of the screen will be about 1 inch less than the tube's full size due to the cabinet surrounding the tube."

Set the Record Straight: CRTs vs. LCDs Better or Worse?: "LCDs constantly refresh their screens, just like CRTs. LCD pixels don't have infinite persistence so they have to be refreshed.

The eyestrain difference is caused by LCD cells having far more persistence than CRT phosphors. When you write a value to a LCD pixel, it stays that way for almost a second before it fades out, while CRTs will fade out in milliseconds.

LCDs generally use around 1/2 to 1/3 the energy of an equivalent CRT monitor.

CRTs emit VLF and ELF (Very Low Frequency and Extra Low Frequency) electromagnetic radiation (caused by the scanning electron beam in the CRT tube), while LCDs do NOT.

LCD displays are more visible even in slightly lower ambient lighting conditions"

Psychology Today: Reinventing yourself: "How's Your Memory?

o Get a pencil and paper ready. Then read these words only once: bed, clock, dream, night, turn, mattress, snooze, nod, tired, night, artichoke, insomnia, rest, toss, night, alarm, nap, snore, pillow.

o Now put the magazine down and try to recall all the words. Give yourself two minutes.

o Did you remember snore and pillow? Probably, because we tend to recall the most recent items and those were last on the list. Did you get artichoke? You probably did because it was distinctive--it didn't go with the other words. Did you remember the word night? It was repeated three times, and that helped you learn it. Did you get the word sleep? Most likely, though it wasn't even on the list!"

Friendster - Hackers

Top 25 Explanations by HACKERS when their programs don't work.

1. Strange...
2. I've never heard about that.
3. It did work yesterday.
4. Well, the program needs some fixing.
5. How is this possible?
6. The machine seems to be broken.
7. Has the operating system been updated?
8. The user has made an error again.
9. There is something wrong in your test data.
10. I have not touched that module!
11. Yes yes, it will be ready in time.
12. You must have the wrong executable.
13. Oh, it's just a feature.
14. I'm almost ready.
15. Of course, I just have to do these small fixes.
16. It will be done in no time at all.
17. It's just some unlucky coincidense.
18. I can't test everything!
19. THIS can't do THAT.
20. Didn't I fix it already?
21. It's already there, but it has not been tested.
22. It works, but it's not been tested.
23. Somebody must have changed my code.
24. There must be a virus in the application software.
25. Even though it does not work, how does it feel?


Write in C (Sung to the tune of 'Let it Be')


When I find my code in tons of trouble,
Friends and colleagues come to me,
Speaking words of wisdom:
'Write in C.'

As the deadline fast approaches,
And bugs are all that I can see,
Somewhere, someone whispers:
'Write in C.'

Write in C, Write in C,
Write in C, oh, Write in C.
LOGO's dead and buried,
Write in C.

I used to write a lot of FORTRAN,
For science it worked flawlessly.
Try using it for graphics!
Write in C.

If you've just spent nearly 30 hours,
Debugging some assembly,
Soon you will be glad to
Write in C.

Write in C, Write in C,
Write in C, yeah, Write in C.
BASIC's not the answer.
Write in C.

Write in C, Write in C
Write in C, oh, Write in C.
Pascal won't quite cut it.
Write in C.

Monday, October 03, 2005

S/N: FJM2W-YWXAP-DA14K-4RNVN
S/N: CVR4H-QDG6E-U846P-4H1VN
S/N: E2TR1-A6E0K-M00D3-4H4L4
S/N: UCR8T-GKL25-H814L-4KHVN

Saturday, October 01, 2005

Coding Horror: How to be Lazy, Dumb, and Successful: "everyone else is just as lazy and dumb as you are"

Why Good Programmers Are Lazy and Dumb

Why Good Programmers Are Lazy and Dumb: "simply because the problem is so stupid, only stupidity can tackle it."

nonadmin - Developing As Non Admin: "Developing As Non Admin

Far too many Windows applications assume that they will be run by a user with administrative rights - just take a look at Known Problems and Keith Brown's Hall of Shame page. This assumption violates one of the basic requirements to be certified as 'Designed for Microsoft Windows XP'. The rest of this page explains what you can do as a Windows developer to avoid this problem."