prime numbers

This is a discussion on prime numbers within the C Programming forums, part of the General Programming Boards category; > any non prime number will atleast have 3 factors (including 1, it's square root, and itself). >>sqrt(21) = 4.582575... ...

  1. #16
    Registered User moonwalker's Avatar
    Join Date
    Jul 2002
    Posts
    282

    hmm

    > any non prime number will atleast have 3 factors (including 1, it's square root, and itself).

    >>sqrt(21) = 4.582575...
    >> not a factor of 21. A factor has to be an integer.

    so what i said was wrong ? i guess not..

    we ALWAYS consider factors as integers... otherwise, we
    can come up with countless factors for every single number
    (think about how many decimal places you can consider...
    the permutations are endless... )

    have fun
    Last edited by moonwalker; 08-20-2002 at 09:55 PM.

  2. #17
    Registered User
    Join Date
    Sep 2001
    Location
    Australia
    Posts
    212
    Sorry to offend you, but I didn't want anyone to be misled

  3. #18
    Registered User moonwalker's Avatar
    Join Date
    Jul 2002
    Posts
    282

    no..

    i didn't take it as an offense anyway

    just clearing it up..

    cool

Page 2 of 2 FirstFirst 12
Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Logical errors with seach function
    By Taka in forum C Programming
    Replies: 4
    Last Post: 09-18-2006, 06:20 AM
  2. prime numbers, counters, help!
    By vege^ in forum C++ Programming
    Replies: 1
    Last Post: 03-10-2003, 04:32 PM
  3. More Prime Numbers
    By mmuhlenb in forum C Programming
    Replies: 3
    Last Post: 02-21-2003, 10:06 AM
  4. Prime numbers
    By Lazy Student in forum C Programming
    Replies: 12
    Last Post: 05-14-2002, 06:53 AM
  5. Homework help
    By Jigsaw in forum C++ Programming
    Replies: 2
    Last Post: 03-06-2002, 05:56 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21