Reply to Re: if...else - in which order

Your name:

Reply:


Posted by Erwin Moller on 11/03/06 09:12

Michael Fesser wrote:

> .oO(David Gillen)
>
>>Nesting if's just leads to confusion in the long run.
>
> Not in properly structured and indented code. With some more braces the
> OP's code is perfectly readable without any comment.
>
> But I consider that personal taste.

I agree 100%.
Use {} everywhere to make things clear.
And also:
if (a==1 && b==2){

is a mess compared to:

if ((a==1) && (b==2)){

That are just a few extra () but makes the code completely clear and leaves
only 1 interpretation (for both PHP and humans who read the code).

Regards,
Erwin Moller

>
> Micha

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация