Using QRect with QHash

In Qt 4.3.3, I found myself needing to use QRect instances as a key in a QHash. However, Trolltech provides no qHash() implementation for QRect, so I implemented this one, and I think it ought to cover the most common uses of QRect. What do you think? uint qHash(const QRect &rect) { uint code = […]

How to Conduct a Good C++ Phone Interview

I’ve interviewed dozens of software engineers, mostly to fill positions involving C++. I’ve also interviewed for about a dozen positions involving C++ and lots of other technologies and languages. I thought I’d share some good on-the-phone interviewing techniques for the interviewer for C++ positions. Before you read this, you shoud know that my interviewing technique […]

PHP: The @ Operator

I’ve seen some confusion online lately about the purpose of the “@” operator in PHP. Let’s figure out exactly what the “at operator” does. PHP holds your hand with error reporting during development by printing error messages to the user’s browser automatically when something goes wrong. This often looks something like this: Warning: mysql_connect() [function.mysql-connect]: […]