View Single Post
Old Apr 26th, 2006, 3:45 AM   #10
mrynit
Hobbyist Programmer
 
mrynit's Avatar
 
Join Date: Mar 2006
Location: WA, USA
Posts: 332
Rep Power: 3 mrynit is on a distinguished road
Send a message via AIM to mrynit Send a message via MSN to mrynit Send a message via Yahoo to mrynit Send a message via Skype™ to mrynit
Quote:
Originally Posted by Jimbo
Why would you use a binary tree per say, instead of just iterating through the elements and checking them linearly? And even bettery, why not use an optimized library function?
binary tree is faster than just going from start to finish(the teacher said that). you can make the bin tree sreach better if you want.

recursion > iteration ?

library function would work. if you want to do it your self then do what i said. thats what first came to mind for doing such a check.
mrynit is offline   Reply With Quote