PHP
-
First Try I started with a simple while loop: Surely, this is non-optimal: how many times will this loop run? 1000? Surely we can reduce it! Possible optimizations include: Start at 3 instead of 0! Surely we can skip numbers if we do find a multiple of 3 or 5? That is, keep adding 3
-
A curious error bumped into me this week while using Doctrine2 at work, when users try to re-register with a previously used username or email (its always their own username or email). A PDOException is always raised in these cases when we save to the database, as it should. The problem emerges when we have