Raised This Month: $ Target: $400
 0% 

Pawn Tutorial on wiki


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Doc-Holiday
AlliedModders Donor
Join Date: Jul 2007
Old 03-01-2010 , 01:13   Pawn Tutorial on wiki
Reply With Quote #1

Question for you guys real quick to make sure i understand this seems simple enough
PHP Code:
//Example of a for loop
new i
new sum
for (i=1i<=10i++)
{
   
sum += i

Steps this follows
</span>1. Check if the condition is true. If so, continue. If not, stop.
2. Run the code.
3. Run the "increment" parameter.
4. Go to step 1.


Now if i do it like.
PHP Code:
//Example of a for loop
new i
new sum
for (i=1i<=10; ++i)
{
   
sum += i

Steps this follows
1. Check if the condition is true. If so, continue. If not, stop.
2. Run the "increment" parameter.
3. Run the code.
4. Go to step 1.



Would that be the difference between the ++i and i++
Doc-Holiday is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 08:44.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode