Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
quarktasche
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
4 ms
·
1.
▲
by
quarktasche
11y ago
Which part? Figuring out how to efficiently calculate a moving average seems like a good question for basic maths skills to me. About complexity theory, there is already a lot of discussion about it's relevancy in the comments. My poin
2.
▲
by
quarktasche
11y ago
Wouldn't the question about the moving average be a good one though? It should be quite obvious that you can calculate a moving average without remembering more than the current average and the window size. Given that, time and space c
3.
▲
by
quarktasche
11y ago
I don't think the std::chrono example is fair at all. In the C++ case, you specify which clock you want. What kind of clock is DateTime.UtcNow()? Is it monotonic? What's the resolution? It's maybe in the documentation, but if
4.
▲
by
quarktasche
11y ago
mv mirrorlist mirrorlist.bak rankmirrors -n 10 mirrorlist.bak > mirrorlist
5.
▲
by
quarktasche
11y ago
If you like this kind of thing go read this write-up of predicting hands in online poker due to bad implementations of shuffling and PRNG algorithms! Its quite a fun read. https://www.cigital.com/papers/download/de
6.
▲
by
quarktasche
11y ago
Wolfram Alpha does! http://www.wolframalpha.com/input/?i=energy+to+heat+1l+of+wa...
7.
▲
by
quarktasche
11y ago
Might not work in some special cases though. Try: def foo(): a = 4 def bar(): print("a = {a}".format(**locals())) bar() foo() which will raise a KeyError, while it will work fine if yo