Posts getaggt mit programming:

Die perfekte E-Mail Regex

/^([w!#$%&'*+-/=?^`{|}~]+.)*[w!#$%&'*+-/=?^`{|}~]+@((((([a-z0-9]{1}[a-z0-9-]{0,62}[a-z0-9]{1})|[a-z]).)+[a-z]{2,6})|(d{1,3}.){3}d{1,3}(:d{1,5})?)$/i


Oder einfach /^.+@.+..+$/i und Pech für den, der was falsches eingibt.

3 Kommentare

Quine (Computerprogramm)

Quine sind Programme, die ihren eigenen quelltext ausgeben, ohne zu 'schummeln', also einfach die Datei zu lesen.

Meine bis jetzt kleinste PHP-Version:

<?php class Quine { function __construct($s) { $c = chr(39); echo $s.$c.$s.$c."; $q = new Quine($s); ?>"; } } $s = '"; } } $s = '; $q = new Quine($s); ?>
Tags: php, programming
3 Kommentare

They Write the Right Stuff

they-write-the-right-stuff

Wie das Softwareteam fürs Space Shuttle nahezu fehlerfreien Code schreibt.

And that's the point: the shuttle process is so extreme, the drive for perfection is so focused, that it reveals what's required to achieve relentless execution. The most important things the shuttle group does -- carefully planning the software in advance, writing no code until the design is complete, making no changes without supporting blueprints, keeping a completely accurate record of the code -- are not expensive. The process isn't even rocket science. Its standard practice in almost every engineering discipline except software engineering.

discuss!