Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int count = 0 ;
- for(;;)
- {
- // do xxxx on array element on every iteration
- xxxx( array[count] ) ;
- if( count == N )
- {
- count = 0 ;
- // Do yyyy this every N iterations
- yyyy() ;
- }
- count++ ;
- }
- int count = 0 ;
- for(;;)
- {
- // Process whole array on every iteration
- for( int i = 0; i < sizeof(array)/sizeof(*array); i++ )
- {
- xxxx( array[count] ) ;
- }
- if( count == N )
- {
- count = 0 ;
- // Do yyyy this every N iterations
- yyyy() ;
- }
- count++ ;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement