# Is ? and Information equivalent? Are they the same in Linux and Windows? [duplicate]

Both in V10.2:

Windows

Linux

So is ? not the same as Information? But in the help files, it looks like ? is a short form for Information ??

## marked as duplicate by Mr.Wizard♦Aug 10 '15 at 6:29

• Related, possible duplicate: (8126) – Mr.Wizard Aug 10 '15 at 6:27

This looks very weird indeed. Here's my theory on what happens.

First, what is ?something equivalent to exactly? It's the same as

Information["something", LongForm -> False]


Note that I wrote "something" in quotes. This is not exactly the same as Information[something] (without quotes). ? is one of those operators that, when appearing at the beginning of the line, will cause the following characters to be interpreted as a string. << is another example of such an operator.

Keeping this subtlety in mind, ? and Information behave in exactly the same way.

Now what about the second weirdness, i.e. that if using a symbol name (not a string), then Information does return the usage message even though the VariationalMethods package was not loaded?

My best guess is that it's because the usage messages for the standard add-ons are replaced by Mathematica with messages stored in \$InstallationDirectory/SystemFiles/Kernel/TextResources/Language/Usage.m (replace Language by your version's language, typically English). I think this is both to allow translations and to have nicely formatted messages with 2D math inside.

It seems that symbols from builtin packages seem to be in this strange state of semi-existence that Names will claim that they don't exist but creating them will immediately load their usage message. This is very similar to the Stub attribute, but Attributes["VariationalMethodsVariationalD"] doesn't find the symbol either.

• I think your first observation is correct; consider MakeExpression[RowBox[{"?", "foo"}], StandardForm] – Michael E2 Aug 9 '15 at 21:42
• I gave this same explaination, perhaps in a bit more detail, in answer to (91216), only to follow the Linked question and see this existing answer of yours. I think these two questions are effectively the same, and I would like to merge them. Do you consider that appropriate? And if I do merge them do you feel that my answer will infringe upon yours? – Mr.Wizard Aug 10 '15 at 6:24
• Actually, after a bit of consideration I am closing this question as a duplicate of (8126) as it does not introduce new material. However (91216) does raise a new question, though as it happens you already answered it here. How should we handle this? – Mr.Wizard Aug 10 '15 at 6:31
• @Mr.Wizard I agree that it is a duplicate. I'm not particularly worried about this kind of "infringement" :-) Go ahead and merge if you like. – Szabolcs Aug 10 '15 at 7:53

Information has an option LongForm.

?... is equivalent to

Information[..., LongForm -> False]

??... is equivalent to

Information[..., LongForm -> True]

• So either way, Information[] is equivalent to one of the ? or ??. But neither [1] nor [2] is working, while [3] is working. – Chen Stats Yu Aug 9 '15 at 16:34
• What I am trying to understand is, (from the linux screenshot), if there is equivalence, I would expect Input[1] or Input[2] to have the same Output as [3]. – Chen Stats Yu Aug 9 '15 at 16:38
• I think the reason for [3] working is explained in my answer to your other question. – m_goldberg Aug 9 '15 at 16:39
• Yes, in this case, that makes sense. I will play around more with these in different order, with fresh kernels. – Chen Stats Yu Aug 9 '15 at 16:41
• Perhaps "equivalent" is too strong a term. The front-end processing for ? and ??, done to translate them into their FullForm, is different from what the more formal Information[...]` receives, and that may account for the difference you see. "translates to" might be a better term than "equivalent" – m_goldberg Aug 9 '15 at 16:49