compare
am 08.04.2006 17:17:22 von PietHow can I stop a function in PHP?
When comparing data I want to stop the function on a hit.
Function compare($data) {
For ($n=1; $n<=10000; $n++) {
For ($m=1; $m<=10000; $m++) {
If $data[$n]==data[$m] {
.
Exit function, or exit for.. --- but how?
}
}
}
How can I avoid comparing 10000 * 10000 times?
Thanks
Piet