Guess a positive integer n
if (n is even) {
n = n/2
} else { /* n is odd */
n = 3n + 1
}
Apply this process repeatedly.
This process will always reach the number 1
Eg : 6 -- 3 -- 10 -- 5 -- 16 -- 8 -- 4 -- 2 -- 1
This is Collatz conjecture and remains open till date !!
Friday, July 14, 2006
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment