# Is this the longest answer on the site?

I understand that there may be incompatible measures of length, especially when Latex and open space are involved. I have sometimes posted jpegs, I think those should be counted as fairly short because the effort was not mine. This one is a pretty good candidate, and we should give credit where credit is due:

EDDDITTT: Now that I have looked at a few long ones: I suppose we cannot really measure the amount of time spent by the person answering. However, I can say that Raymond's answers score big in this department: how many seconds does it take the Latex to render, from the instant you open the question?

EEEDDIIITTTTT: Yes, I think that is the way to go. Joriki's top-of-the-charts sits there for about 15 seconds, but then suddenly renders it all. Raymond's new one gets started sooner but takes about 35 seconds to make it all the way through, as I scroll down I can see the new bits going from pre-Latex (gray) to rendered, so I know that the whole thing has not yet been finished.

EEDDIITTEEDDIITT Monday December 31: The beginnings of an explanation. My two very long posts are mostly some C++ output I pasted in. I actually remember re-running the program because the answer page told me 30,000 characters was the maximum. Here is the "trick," such as it is. Raymond's new answer, currently fourth in the ranking, has dozens to hundreds of separate Latex items. The peculiar thing about Joriki's top post is that it is just four separate Latex array items, each very, very long, and overall quite repetitive. So the system probably expects the number of separate Latex items to be comparable to the total mass of Latex characters, and, in short, allows extra character length if there are very few dollar signs.

EVEN MORE EDIT: I copied Joriki's answer and posted it as an answer to For which primes $p$ does $x^2-31y^2=-p$ have solutions? and the system accepted it just fine. I guess I will delete it in a bit, after a few have seen it. Evidently it would take days before Asaf's long-post-search query would notice it....I did delete it, then edited the source down to one line of gibberish. The odd final outcome is that it will not let me add another answer at the same question. So perhaps you can get away with one long answer this way, but it won't permit a second.

• data.stackexchange.com/mathematics/query/64341/… (The first three posts contain massive pieces of code and data; but the fourth answer is a huge block of text already.) – Asaf Karagila Dec 27 '12 at 20:57
• Just FYI, there is a 30,000 character limit on posts, so there is a hard limit on the longest possible answer. – Mad Scientist Dec 27 '12 at 20:58
• @MadScientist: But joriki's top post has ~54k chars. – Asaf Karagila Dec 27 '12 at 20:59
• @AsafKaragila, those are wonderful. I had forgotten the blocks of data I put from C++ programs. Let me look at the fourth one you mention. Are you sure the size figure is characters? – Will Jagy Dec 27 '12 at 21:07
• Of course not... – Asaf Karagila Dec 27 '12 at 21:12
• @AsafKaragila no idea how the post circumvents the limit, the limit itself is older than that post. Probably some escaping or latex stuff happening that confuses the size limit. – Mad Scientist Dec 27 '12 at 21:16
• I'm going to run the query on that page again tomorrow, it gives three long posts by Raymond but not this one. It may take a few days for a new post to be considered. – Will Jagy Dec 27 '12 at 21:24
• From Asaf's table my vote would go to Javier's answer. Observe that it's a follow up to two long answers (also about the degree). – Raymond Manzoni Dec 27 '12 at 22:35
• @RaymondManzoni, Javier's answer is a strong effort, I think we must respect his competitive instinct, but I time it as just under 30 sends to your 35. Computer and browser dependent, I imagine, but still. Your answer, I keep scrolling down and there is still more unrendered gray pre-Latex. I edited in the timing-Latex idea into my question, after your comment. – Will Jagy Dec 27 '12 at 22:42
• @WillJagy: So that there are some people here that are more harmful to environment than others and ... I am on the top... Gasp!! But you began a new competition with this thread becoming this way the most meta-harmful ha ! – Raymond Manzoni Dec 27 '12 at 22:58
• Thanks @Will I'll accept that... provisory! Now where is my prize? Is is a Powerful (energy efficient) Computer or... No not the source code of the latex interpreter for optimization! I noticed (on my Mac at least) that the analysis was slower and slower after each modification... Thank you both for the entertainment and the comparison script anyway! – Raymond Manzoni Dec 28 '12 at 0:40
• (comment continued) I decided to try pasting it into a "Your Answer" window and see what happens. It seems to work fine, better than I expected (sorry, I forgot to time it), so perhaps I'll try to get it finished and post it sometime in the upcoming few weeks. – Dave L. Renfro Dec 28 '12 at 20:51
• Will : I did some timing tests today and, instead of the 45, 40 and 30s for my first, second and Javier's answer I got less than 25, 20 and 16s (i.e. a speedup of a factor 2! and this with a fresh, cache-empty Safari browser). Are some anti-devil forces at work ? ;-) or just a kind of 'cluttering' of my computer the first time (I tried quite some times then)... – Raymond Manzoni Jan 2 '13 at 13:57
• @RaymondManzoni, there is ample evidence that computers hate us, because we can move around and they can't. Other than that....I am gradually becoming satisfied that loading time is well correlated with number of distinct Latex items. Hence, joriki's repetitive answer, where it does take those 15 seconds to do whatever it does for a Latex section, but then everything is rendered all at once. Or, put another way, loading time is well correlated with typesetting time and human effort. Times: things do better for me if I turn off the computer and electricity (power strip) every night. – Will Jagy Jan 2 '13 at 19:26
• @Daniel: This is a site full of mathematicians, and mathematicians are well known for their inability to count concrete things correctly. – Asaf Karagila May 31 '16 at 3:50

To answer the title question, as of today, December $30^{th}$ $2012$, the answer you linked to is the fourth longest answer on the site as measured by the number of characters.

See the data query which appeared in Asaf's comment.

• Oh, very good. I thought it might take a few days for that data query thingie to realize Raymond's answer was there. My two are long only because of huge C++ output I pasted in. So the mystery still remains, how does Joriki's answer get counted so high? Or, if it really is so huge, why did the system accept it? EDDITTTT: I believe I understand. Instead of a hundred different Latex items, Joriki's post is just four very long Latex array items. – Will Jagy Dec 31 '12 at 19:34
• Note that I posted Joriki's extra-long answer at math.stackexchange.com/questions/268294/… and the system accepted it. – Will Jagy Dec 31 '12 at 20:03

The SEDE query linked to in Asaf's comment and Eric Naslund's answer is somewhat misleading because of the way the SEDE data is provided. Specifically, the Body column in the Posts table is the rendered HTML, not the bare Markdown. The difference between bare Markdown and rendered HTML is why it is possible that the SEDE thinks there is a 50,000+ character answer, even though there is a known limit of 30,000 characters for posts. Bare Markdown is saved in the Text column of the PostHistory table, provided you are looking at the right PostHistoryTypeId.

(Interested readers can learn more in the Database schema documentation for the public data dump and SEDE from Meta Stack Exchange.)

Some enterprising soul has provided a new query to get the longest answers by Markdown.

Of note, joriki's answer doesn't even crack the top 100 in this new query. It achieved its long HTML rendering because the apostrophe ' character from the Markdown was replaced with &#39;. Some 9000+ instances each expanded to five characters.

• It would be nice if the new query had a field with the user name who posted the post... Just sayin'... :-P – Asaf Karagila May 30 '16 at 21:28
• @AsafKaragila posted an answer showing the top 16. Six of them are mine. Fits the kind of questions where I am willing to put in considerable effort. – Will Jagy May 31 '16 at 18:35
• Fine, @Asaf, you can have your names. – user642796 May 31 '16 at 20:15
• Much obliged... – Asaf Karagila Jun 1 '16 at 1:08

Here is the beginning of the list arjafi found, longest answers by Markdown. Six of the top sixteen are me. This is consistent with my experience in elementary number theory, if you have no idea what is going on, see what can be computed, look for patterns, maybe some of that can be proved.

Another area seems to be fractional iteration, it is a big job, given a function $g(x),$ to find a function with $f(f(x)) = g(x),$ at least in a semi-infinite interval in the real line.

• Another record that I found interesting: I was playing with some of the queries on data explorer for fun, and the top down voters were also some of the top up voters I guess because they are more active on the site, and there were some random people that just down voted a lot and there was one notable exception among the site leaders that had not down voted even once. That happens to be you. – user5389726598465 Jun 26 '17 at 2:26