Swift
String internals
Why can't you index a String with an integer like text[3], and why is text.count O(n)?
String internals
Why can't you index a String with an integer like text[3], and why is text.count O(n)?
SwiftShort answerExpert
You need a struct ImageBuffer that wraps a large pixel buffer, keeps value semantics, and…
#performance
SwiftShort answerAdvanced
Say your resume claims "ContiguousArray is faster than Array." In a pre-interview the int…
#performance
SwiftShort answerAdvanced
You need to put a very large Dictionary, hundreds of thousands of entries, into a struct …
#performance
CS fundamentals and algorithmsMultiple choiceAdvanced
You iterate over 100,000 coordinates and sum distances. Between these two versions, what'…
#performance