The Daily Static
  The Daily Static
UF Archives
Register
UF Membership
Ad Free Site
Postcards
Community

Geekfinder
UFie Gear
Advertise on UF

Forum Rules
& FAQ


Username

Password


Create a New Account

 
 

Back to UserFriendly Strip Comments Index

code styles by dennismv2004-12-30 06:44:05
  i prefer by stacato2004-12-30 06:50:03
    do{} while() is appropriate when by BloodyViking2004-12-30 07:00:13
      my purpose was to by dennismv 2004-12-30 07:10:29
avoid code duplication somehow. First version had a duplicate x(). 2nd doesn't.

both codes can have while() at the top. I did do{} while() in the second one for variety :)

Having a break in the while loop was the only way I could see how I can create a functionally equivalent code, without duplicating x().

There may be another way to rewrite things, if I know about the specifics of x(), y() and condition(), it is sometimes possible to rewrite the code in such a way as to use a while(){} without a break inside. But that's a different thing.
[ Reply ]
        Well you can always by jayfarm2004-12-30 07:26:12
          I agree by dennismv2006-11-19 12:55:59

 

[Todays Cartoon Discussion] [News Index]

Come get yer ARS (Account Registration System) Source Code here!
All images, characters, content and text are copyrighted and trademarks of J.D. Frazer except where other ownership applies. Don't do bad things, we have lawyers.
UserFriendly.Org and its operators are not liable for comments or content posted by its visitors, and will cheerfully assist the lawful authorities in hunting down script-kiddies, spammers and other net scum. And if you're really bad, we'll call your mom. (We're not kidding, we've done it before.)