Date: 2017-06-21 12:54 pm (UTC)
momentsmusicaux: (0)
Oh yeah, I definitely know that isset($array['key']) is faster than in_array($array, 'value')[*], but I couldn't tell you anything specific in big O notation or ratios.

The other advantage of using a keyed array is that you prevent duplicates when you're adding items.


* I can never remember parameter order here, PHP is inconsistent with the order of needle and haystack parameters. Thanks PHP!
This account has disabled anonymous posting.
(will be screened if not validated)
If you don't have an account you can create one now.
HTML doesn't work in the subject.
More info about formatting

June 2025

S M T W T F S
1 2 3 4 5 6 7
891011121314
15161718192021
22232425262728
2930     

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Jun. 8th, 2025 10:05 pm
Powered by Dreamwidth Studios