trivia

MySql: MyISAM vs. Inno DB!

What are the differences between MyISAM and Inno DB types in MySql? ...

Which is your favorite programming trivia?

... and that has helped a lot to remember some programming concept. ...

Stacks - why PUSH and POP?

I was wondering why we use the terms "push" and "pop" for adding/removing items from stacks? Is there some physical metaphor that caused those terms to be common? The only suggestion I have is something like a spring-loaded magazine for a handgun, where rounds are "pushed" into it and can be "popped" out, but that seems a little unlikel...

What are the valid values of the expression (uninitialized_bool ? 1 : 2)?

What is the set of valid outputs for the following, according to the standard? bool x; cout << (x ? 1 : 2); edit: unknown(google) has got it. In gcc my code was crashing because of sprite.setFrame(isPressed ? 0 : 1) with the conditional returning 28! ...

.net AppSettings historical trivia

One of the previous developers where I work habitually, consistently used: ConfigurationSettings.AppSettings["Foo"].ToString() It twigs me a bit since AppSettings collection items are already strings, but I got to wondering: way back in the ancient days of .net 1.0 and 1.1, did the collection store its items as type Object necessitat...

Is "else if" one whole or two separate keywords in Java?

I happen to read the practicing material for SCJP certification, and I just tripped over a chapter of flow control et al, where they give the impression that "else if" is a keyword on its own. I have always thought that it was just a normal else, containing nothing but an if block, braces omitted. So, which is it? Edit: I'd like to em...

Why are many ports of languages to .net prefixed with 'Iron'?

Was discussing over lunch why several ports of languages to the .net framework are prefixed with 'Iron'. e.g. IronPython IronRuby IronLisp IronScheme IronPHP Anyone out there know? (language list sourced from http://www.dotnetpowered.com/languages.aspx) ...

Why does python -V write to the error stream?

I was writing a script to inspect python's version on my system and I've noticed that python -V writes to the error stream, while python -h, for instance, uses the standard output. Is there a good reason for this behavior? ...

Why does COBOL have both `SECTION` and `PARAGRAPH`?

Why does COBOL have both SECTION and PARAGRAPH? Can anybody explain why the designers of COBOL created both SECTIONs and PARAGRAPHs? These have been around since the initial release of COBOL so I suspect the real reason for their existence has long since gone away (similar to things like NEXT SENTENCE which are still in the language spe...

What are some programming problems you initially get WORSE at?

In programming, as many professions, there are mistakes you'll make now that you may not have made as a beginner. For instance, consider pointers: In C++, is there any difference between arrays and pointers? The beginner will say yes, they are two completely different concepts, and treat them as such. The intermediate programmer (...

Detect ASP.NET version from output HTML?

Ok, this is probably a trivial thing to know - hence the trivia tag! - but does anyone know of any difference in final output that would give away the version of the runtime that was used? In other words, if you visit a website and you know it's generated via ASP.NET, are there any telltale things about the markup that would give away w...

What was the first Hello World Application written in?

Possible Duplicate: Where does Hello world come from? What was the first Hello World application written in? ...

Categories and Tagging in a Web Application

I'm creating a small trivia site and would like to know if anyone has insight as to how I could categorize the trivia questions/quizzes so that it does not hinder the "typical browse around and answer questions" type of user, as opposed to one who uses the search engine to explicitly find trivia of interest. Trivia content will be creat...

.NET: What is the object header used for?

In .NET there are 8 bytes of overhead for each object. 4 bytes are a pointer to the object's type. What are the other 4 bytes, known as the object header, used for? ...

Maximum number of fields for a C++ object

This answer states that in Java the maximum number of fields an object may have is 65536. Is there any such limit imposed on an object in C++? ...

Is there an HTML tag that can be used anywhere in the DOM?

This sounds a bit like a trivia question, but it would help me figure out my options solving an actual problem. Is there an HTML tag that can be used anywhere in the DOM? (something to be used as a placeholder) An HTML5 tag would be ok. No XHTML unfortunately. I've thought about it for a bit, the only tag I can come up with is <script/>...

What programming language would James Bond have programmed in?

Until the recent Bond movies James preferred British made gadgets. The classic for me is from "You Only Live Twice", as there is real British gyro-copter nicknamed Little Nellie which (in the movie) shipped in 4 suitcases. In the action scenes Little Nellie took on several helicopters. This nifty British made gadget got me wondering ...