#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2000
    Posts
    14
    Rep Power
    0
    Which solution is the best to display on the screen through the Web?
    1.
    $str= '' ;
    For($i=0 ; $i<100 ; $i++)
    $str.= 'aaaaaaaaaaa bbbb ccccccc' ;
    printf('%s', $str) ;

    or
    2.
    $str.= 'aaaaaaaaaaa bbbb ccccccc' ;
    For($i=0 ; $i<100 ; $i++)
    printf('%s', $str) ;
  2. #2
  3. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2000
    Location
    France
    Posts
    16
    Rep Power
    0
    The second should be faster as you don't have to do 100 concatenations and just display the string.


Similar Threads

  1. GUI takes forever to display
    By coredumped in forum Java Help
    Replies: 7
    Last Post: November 21st, 2003, 10:43 AM
  2. Hardware (un)support for performance counter.
    By peenie in forum Computer Hardware
    Replies: 0
    Last Post: October 28th, 2003, 12:48 PM
  3. display text box upon selecting on list menu
    By robee in forum HTML Programming
    Replies: 7
    Last Post: October 14th, 2003, 11:11 AM
  4. display db records from multiple tables problem
    By blodefood in forum ASP Programming
    Replies: 5
    Last Post: October 6th, 2003, 08:16 AM
  5. Replies: 12
    Last Post: September 24th, 2003, 08:59 PM

IMN logo majestic logo threadwatch logo seochat tools logo