d2jsp
Log InRegister
d2jsp Forums > Off-Topic > Computers & IT > Programming & Development > Text From File Manipulation
Prev12
Add Reply New Topic New Poll
Member
Posts: 2,183
Joined: May 8 2009
Gold: 1.00
Apr 15 2014 12:13am
To do that for the entire file as an unspecified amount of questions. I would use a for loop or a while loop?
Member
Posts: 1,995
Joined: Jun 28 2006
Gold: 7.41
Apr 15 2014 12:21am
Quote (Kellye @ Apr 15 2014 01:13am)
To do that for the entire file as an unspecified amount of questions. I would use a for loop or a while loop?


If you want to do a set of operations over and over? Yes, a loop would fit just nicely.
Banned
Posts: 19
Joined: Apr 25 2014
Gold: 0.00
Apr 26 2014 12:03am
nb
Member
Posts: 4,728
Joined: Jan 15 2008
Gold: 4,102.02
Apr 29 2014 10:15am
If you want to loop undefinately, i usually do this:

Code

try
{
while(true)
{
// Read
// Do actions
}
}
catch (EOFException)
{
//Close your streams//Whatever you're using to read.
}
Member
Posts: 178
Joined: May 4 2014
Gold: 1.00
May 4 2014 04:34pm
This post is a violation of the site rules and appropriate action was taken.

Hi Guys!
I'm new here, i need a little Donate For a start :)
Very big thanks boys and have a nice day!
Member
Posts: 1,995
Joined: Jun 28 2006
Gold: 7.41
May 4 2014 05:15pm
This post is a violation of the site rules and appropriate action was taken.

Quote (Haarder @ May 4 2014 05:34pm)
Hi Guys!
I'm new here, i need a little Donate For a start :)
Very big thanks boys and have a nice day!


Big man actually sells his psuedocurrency. All you need is a paypal account, deadbeat. gtfo
Member
Posts: 192
Joined: Mar 26 2014
Gold: 0.00
Warn: 10%
May 5 2014 05:11am
woww
Member
Posts: 517
Joined: Jun 19 2010
Gold: 4,418.44
May 5 2014 08:40am
Quote (Minkomonster @ Apr 15 2014 10:46am)
You want to think object oriented? It is actually pretty easy. Easiar, and more intuitive than procedural in my opinion. Because we do it intuitively.

What is an object? It is an abstract model of something. An object contains fields which define what they are and methods which define what the object can do.

Let's define some objects.

<etc etc etc etc>




I found this entire post to be more informative than actual classes I attended on Object Oriented Programming in school.

+1
Go Back To Programming & Development Topic List
Prev12
Add Reply New Topic New Poll