News for hackers. Stuff that matters.
Re:I had to give a wrong answer to get the job (2017) by munificent on Monday July 19, 2021 @02:54PM (#27886077)
I feel like I've replied to this same thing about five times now, but, yes, I completely understand the latency concern with growing a dynamic array. At the time, we weren't talking about it. Their question was, "What is the complexity of this?" And I said, "It's constant time over a series of appends." We didn't get past that.
Re:I had to give a wrong answer to get the job (2017) by asr21 on Monday July 19, 2021 @03:13PM (#27886241)
The guy worked at EA for 8 years.. He must know what he is talking about
Re:I had to give a wrong answer to get the job (2017) by sudopluto on Monday July 19, 2021 @04:19PM (#27886847)
he also wrote the crafting interpreter book : )
Re:I had to give a wrong answer to get the job (2017) by munificent on Monday July 19, 2021 @06:09PM (#27887853)
And Game Programming Patterns, which has a chapter on the performance effects of contiguous data:

https://gameprogrammingpatterns.com/data-locality.html

:)

Re:I had to give a wrong answer to get the job (2017) by wffurr on Monday July 19, 2021 @05:02PM (#27887223)
That means nothing. Time != experience. You have to have actually learned during that time for it to count for anything.