Identifying Indeterminate elements [closed]

I want to identify if a variable, which is the result of a calculation, is Indeterminate. I was trying to do this using If[]. For example

p = Log[PDF[NormalDistribution[0, 1], 1000000.]]
If[p==Indeterminate,1,0]
If[p=="Indeterminate",1,0]


But it is not working. Could you please point me to a better strategy?

-
Voting to close for TL as this is directly addressed in the documentation for Indeterminate. –  Oleksandr R. Sep 12 '12 at 15:23
Procrastinator, you have only one down-vote on this question, and two up-votes; that's a net gain of +8 points. I don't think this needs to be deleted. If you get a bunch of additional down-votes or if it really bothers you I can delete it; flag again if needed. –  Mr.Wizard Sep 12 '12 at 16:51

closed as too localized by Oleksandr R., F'x, rm -rf♦, belisarius, Ｊ. Ｍ.Sep 22 '12 at 2:48

This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.If this question can be reworded to fit the rules in the help center, please edit the question.

You can use === (SameQ). Indeterminate is a special head, so that Equal (==) on it remains unevaluated:

Indeterminate == Indeterminate

(*  Indeterminate == Indeterminate *)


while

Indeterminate === Indeterminate

(* True *)

-
Awesome! Thanks! I will accept the answer in 10 minutes. –  user2277 Sep 12 '12 at 15:19
@Procrastinator It is a recommended practice to wait for some time for better answers to appear. Normally one can give it a day or two, but that also depends on the question. –  Leonid Shifrin Sep 12 '12 at 15:20
Yes, I understand. In this case, this answer solves my problem. –  user2277 Sep 12 '12 at 15:21
MatchQ[] could be an alternative here, methinks... –  Ｊ. Ｍ. Sep 13 '12 at 13:43
@J.M. Sure, MatchQ reduces to SameQ for patterns not containing blanks etc. But it seems a less direct way to me. –  Leonid Shifrin Sep 13 '12 at 13:46