What would you like to share?
Hi, I'm new to this repo. So please enlighten me if that's just the way things are done here.
In the linear search file, I noticed that it returns 1 when an element is found and 0 otherwise.
Not a fatal error per se, but isn't a searching algorithm supposed to return the position/index at which the required value was found, like done in other files? Why make a difference for a trivial linear search?
Additional information
No response
What would you like to share?
Hi, I'm new to this repo. So please enlighten me if that's just the way things are done here.
In the linear search file, I noticed that it returns 1 when an element is found and 0 otherwise.
Not a fatal error per se, but isn't a searching algorithm supposed to return the position/index at which the required value was found, like done in other files? Why make a difference for a trivial linear search?
Additional information
No response