What do you call a 9999-sided polygon?
A nonanonacontanonactanonaliagon.
While polygons are important in computer graphics, what’s special about a 9999-gon? Well, not much really, but it made me think about the nomenclature for polygons: the word “polygon” comes from the Greek polygōnon, meaning “many-angled”. Polygons are usually named according to the number of sides, combining a Greek-derived numerical prefix with the suffix -gon, e.g. pentagon (5-gon), dodecagon (12-gon) or icosagon (20-gon) — with the triangle, quadrilateral and nonagon (9-gon) being notable exceptions. But beyond decagons, professional mathematicians generally prefer the numeral notation (n-gon).
Also, a 10000-gon is called a myriagon.
I was expecting you to talk about constructibility here, but I couldn’t work out in my head whether a 9,999-gon was constructible. (Although it’s clearly not – in my defence, it was very early in the morning.)
But it did make me think of an interview question that came up the other day:
Take a row of, say, 9,999 coins, all heads up, and flip all the coins in positions divisible by 2, then flip all the coins in positions divisible by 3, and so on, what do you see at the end? How many coins are heads up? Which ones?
The first guess that came into my head was that the square-free numbers might be heads up. This isn’t quite right, though, and I’m fairly sure the answer isn’t “the constructible polygons”; but I wonder if there are any questions that aren’t apparently related to polygon constructibility, but nevertheless end up having the same answer.
Oh, and by the way, a nonagon is sometimes (but rarely, apparently) called an enneagon, which fits in with the otherwise prevalent Greek motif.
With regards to the coin flips, aren’t you indirectly sieving for primes (although this makes no comment on whether they will be heads or tails!)?
Just getting this clear in my head. Flipping divisible by two will flip 2,4,6…9996,9998. Flipping divisible by 3 will flip 3,6,9,12 (importantly)… 9999, 4 flips 4,8,12,16, etc.
So, you’re asking if there’s a way to calculate how many times each coin will be flipped? If we can do this mod 2 we know how many heads are left showing or something?
J.
Hmm, so 2 is flipped once.
8 is flipped only 3 times.
12 is flipped (2, 3, 6, 4) 4 times.
5 is flipped once
7 is flipped once.
11 is flipped once
any prime is flipped only once, but non-primes are flipped N times where N is the number of factors. So limiting the problem to 9999 is probably computable quite quickly. Or am I barking up the wrong tree?
Everyone’s barking up the right tree: certainly primes get flipped exactly once, and we really are talking about “number of flips mod 2” – there are no secret subtle tricks in the question.
So, for each n, the question is really this: “how many distinct factors does n have, mod 2”? (A more general questions is, “how many distinct factors does n have?”)
(Let’s ignore the trivia, like “do 1 and n count as factors, or are we just talking about trivial factors?” They’re really concerned with finessing the details at the end or, in an interview scenario, making sure the candidate knows that that kind of thing is important in general.)
So this, ultimately, sounds like a more general question or perhaps two):
Firstly, can we calculate the number of distinct factors of a given integer?
If we can’t calculate it exactly, then what does the “number of distinct factors” function look like, asymptotically?
But what I’m really keen on is finding standard mathematical questions like this, and using them to back-track towards interview-style questions that reflect them.
Someone said to me its decimmillavacuusunusagon but I cant really understand why….