help me , please ?!? 
Author Message
 help me , please ?!?

Hi,


Quote:
> someone can help me please to understand what this program doing:

Absolutely nothing.

The program does for every x from 1 to 500 the following: It increases a
variable y from 1 to x/2, and counts every step, in which a certain
condition is true, in the veriable s. Obviously, the maximum value for
s must be x/2. Iff s = x (that is, never), x is printed out.

 - Sebastian

--
This posting is sent in compliance with art. 22 of the German basic law.



Wed, 18 Jun 1902 08:00:00 GMT  
 help me , please ?!?
what does the program do if you change line number 13 to read like this:

if x mod y = 0 then s:=s+y;

notice i've change the 1 with y in s:=s+y instead of s:=s+1

thanks in advance

Quote:

>Hi,


>> someone can help me please to understand what this program doing:

>Absolutely nothing.

>The program does for every x from 1 to 500 the following: It increases a
>variable y from 1 to x/2, and counts every step, in which a certain
>condition is true, in the veriable s. Obviously, the maximum value for
>s must be x/2. Iff s = x (that is, never), x is printed out.

> - Sebastian

>--
>This posting is sent in compliance with art. 22 of the German basic law.



Wed, 18 Jun 1902 08:00:00 GMT  
 help me , please ?!?
Hi,


Quote:
> what does the program do if you change line number 13 to read like this:

Is this going to be a quiz? I hope I can win something :-)

Quote:
> if x mod y = 0 then s:=s+y;

In this case, the program sums up all divisors of x, and stores the sum
in y. Therefore, the program prints out all numbers that are equal to all
their divisors summed up. I don't know what's so special about these
numbers, but then again I'm not a numbers expert.

 - Sebastian

--
If you read this text, your newsreader doesn't support signature frames.



Wed, 18 Jun 1902 08:00:00 GMT  
 help me , please ?!?

Quote:

>In this case, the program sums up all divisors of x, and stores the sum
>in y. Therefore, the program prints out all numbers that are equal to all
>their divisors summed up. I don't know what's so special about these
>numbers, but then again I'm not a numbers expert.

Those are called Perfect Numbers.

Jud McCranie



Wed, 18 Jun 1902 08:00:00 GMT  
 help me , please ?!?
Hi,


Quote:
> Those are called Perfect Numbers.

Yes, of course. I think we had quite a lengthy thread about this topic a
few weeks ago.

 - Sebastian

--
YOUR AD HERE!



Wed, 18 Jun 1902 08:00:00 GMT  
 
 [ 5 post ] 

 Relevant Pages 

1. please, I beg of you help me please.

2. HELP ME PLEASE I NEED HELP ON PROGRAMMING THIS>>>>|||

3. DbiAddIndex...Help me please.

4. Help me Please!!!

5. More noob help needed please: 'asm'

6. Refresh data in dbtext??????? help me please

7. Help needed, Please

8. Help me, PLEASE ! (ADO)

9. DBase IV Table location help needed (Please)

10. HELP ME PLEASE!!!!!!

11. |°|°| Refreshing TQueries: Help me please

 

 
Powered by phpBB® Forum Software