It is currently Tue Sep 07, 2010 6:47 am


All times are UTC [ DST ]


Ask on Codemiles community and get answers Free and Fast :

Ask your C-C++ questions ,C-C++ codes,C-C++ tricks ,C-C++ faq ,C-C++ answers .and more

Our guest share with us your code snippets , your programming problems , your open source projects ,read articles and post yours .







Post new topic Reply to topic  [ 6 posts ] 
  Print view Previous topic | Next topic 
Author Message
 Post subject: While loop
PostPosted: Thu Apr 09, 2009 3:43 am 
Offline
Newbie
User avatar

Joined: Thu Apr 09, 2009 2:39 am
Posts: 3
Has thanked: 0 time
Have thanks: 0 time

Another program I can't figure out. Any help would be appreciated.

set y = 3
set x = 2
set z = 0
while x<12
z = x + y
x = y
y = z
End While
Output y


TOP
 Profile Send private message  
 
| More
 Post subject: Re: While loop
PostPosted: Thu Apr 09, 2009 10:26 pm 
Offline
Mastermind
User avatar

Joined: Tue Mar 27, 2007 10:55 pm
Posts: 1588
Location: Earth
Has thanked: 10 time
Have thanks: 17 time

thanks a lot ,

_________________
Currenlty programming with : java , html , php , and javascript .


TOP
 Profile Send private message  
 
| More
 Post subject: Re: While loop
PostPosted: Wed Apr 22, 2009 6:54 am 
Offline
Newbie
User avatar

Joined: Sat Apr 18, 2009 1:20 pm
Posts: 20
Location: UK
Has thanked: 0 time
Have thanks: 0 time

Whats the problem in this program what output you are getting

_________________
Lincoln Solicitors


TOP
 Profile Send private message  
 
| More
 Post subject: Re: While loop
PostPosted: Fri Jul 17, 2009 6:11 am 
Offline
Newbie
User avatar

Joined: Wed Apr 15, 2009 7:18 am
Posts: 32
Has thanked: 0 time
Have thanks: 0 time

Even easier to use than the for loop is the while loop. A while loop doesn't initialize or increment any fields automatically as part of the command, it just tests a condition and executes the loop for as long as the condition remains true. simple ex:
var x = 0;
while (x<10) {
document.write(x);
x++;
}

_________________
Atlanta Custom Web development


TOP
 Profile Send private message  
 
| More
 Post subject: Re: While loop
PostPosted: Sun Jul 19, 2009 8:14 am 
Offline
Mastermind
User avatar

Joined: Tue Mar 27, 2007 10:55 pm
Posts: 1588
Location: Earth
Has thanked: 10 time
Have thanks: 17 time

document.write(x); ????

It is C++ . haha . ? i think it is javascript .

_________________
Currenlty programming with : java , html , php , and javascript .


TOP
 Profile Send private message  
 
| More
 Post subject: Re: While loop
PostPosted: Mon Jul 20, 2009 9:14 am 
Offline
Newbie
User avatar

Joined: Mon Jul 20, 2009 8:53 am
Posts: 1
Has thanked: 0 time
Have thanks: 0 time

Thanks a lot.I am really appreciate your programing figure.


TOP
 Profile Send private message  
 
| More
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 


 Similar topics
 Topic title   Forum   Author   Replies 
 java loop at end of code ... soooo close i hope  Java  seaplus  0
 I NEED SOME HELP IN THE FOR LOOP PLZ .. IAM JUST A BEGINNER  C-C++  sheeko911  4
 for statement loop indefinitely  Java  AskBot  3
 Need help with a loop  Java  SNW  1
 C++ While loop  C++ examples  mileloader  0

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  





Home
General Talks
Finished Projects
Code Library
Games
Tutorials

Java
C/C++
C-sharp
php
Script
JSP/Servlets
Ajax
ASP/ASP.net
Google SEO
Database
Communications
Phpbb3 styles
Photoshop tutorials
Flash tutorials
Find a job






Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
All copyrights reserved to codemiles.com 2007-2009
mileX v1.0 designed by codemiles team