in reply to Re: Re: Strange benchmark result that has me totally confounded
in thread Strange benchmark result that has me totally confounded
As perldoc perlsyn says:
In other words, the "foreach" loop index variable is an implicit alias for each item in the list that you're looping over.
I don't think local will do it either; not unless you want an empty array or are doing something a lot more clever than I can imagine. You need to reset the values of the array for each benchmark iteration.
|
|---|