|
Mailing Lists
|
Home /
Groups /
ColdFusion Talk (CF-Talk)
Another Best practises question
Is there a better way of writing:David Adams 02/19/04 03:19 P Probably not. There might actually be a more compact way of doing thisPaul Kenney 02/19/04 03:56 P I'd agree with Paul. The only other way I could think of is:Charlie Griefer 02/19/04 04:22 P Is there a better way of writing: <cfif ArrayIsEmpty(arr_one) AND ArrayIsEmpty(arr_two)> Probably not. There might actually be a more compact way of doing this test, but the great thing about the code you posted is that the function names convey clearly what the intent of the test is. Paul Kenney WebMaster, CorporateWarriors.com 916-663-1963 Is there a better way of writing: <cfif ArrayIsEmpty(arr_one) AND ArrayIsEmpty(arr_two)> I'd agree with Paul. The only other way I could think of is: <cfif NOT arrayLen(arr_one) AND NOT arrayLen(arr_two)> which isn't necessarily any more compact, nor is it any more readable in the code. Any performance differences between the two would be negligible at best. ----- Excess quoted text cut - see Original Post for more -----
|
May 21, 2013
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||