Re: specific values in loops

From: Oscar kind (oscar_at_danwa.net)
Date: 11/30/04


Date: Tue, 30 Nov 2004 06:35:28 +0100

Danny Gopie <ouygiytf@jhgvkuy.nl> wrote:
Oscar Kind <oscar@danwa.net> wrote:
>>
>> Which values do you want to print? I see three values: i, a and aantal.
>>
>> You can change the output by using a different expression than
>> (a < aantal). Or did you mean (a + " < " + aantal)?
>>
> Well, i want to print the value of a. But only the values of "a" that are
> smaller then the input var "aantal" .What kind of changes do you mean with
> the output?
>

You already only print something when a < aantal. So that's covered.
At the moment, you print the value of (a < aantal), which is a boolean.
To print the value of a, you would change the println call to an
expression that evaluates to a...

PS: Please try NOT to top-post in the future (it is the norm on this
    newsgroup, and mixing top-posting and bottom-posting is horrible for
    readability).
PPS: Please keep the attribution; If "foo" said something, keep the
     generated line that states that "foo" said it.

-- 
Oscar Kind                                    http://home.hccnet.nl/okind/
Software Developer                    for contact information, see website
PGP Key fingerprint:    91F3 6C72 F465 5E98 C246  61D9 2C32 8E24 097B B4E2