Ezekiel Kadner: are u working in See Sharp (C#)coz if sooul find thisfor (precondition,what has to be true to continue,postcopndition){// sumething}so first before he enters a loop he do the preconditionthan chek the 2 thing and then enters the loopafter he does the post conditionhere is an example of forfor (int i=1,i{}this will be like i=Form1.width but u can do it asi=1+1+1+1+1+1+1+1...+1 in the for loopthis is an stupid example ofcoursefor is used in much better causes...Show more
Tomeka Hameen: Pre Condition loops are those in which you first define condition and if condition become true the loops executed otherwise not... and in Post-condition loop .. loop must executed ONCE and then it checks condition and if condition matches it act accordingly...While is Pre Condition loop.For is Pre Condition loopdo...while is post-condition loop.hopes this will help...Show more
George Dingeldein: Postcondition
Ismael Sixon: Pre-condition loop - check the condi! tion first, only run the loop if it passes. A pre-condition loop will be skipped all together if the condition starts out false.Post-condition loop - check the condition at the end of the loop, after executing it one time. A post-condition loop will always be executed once, and if the condition is false at the end of the single pass through the loop that's it, otherwise it gets repeated....Show more
No comments:
Post a Comment