Show that the language {p | p is a C++ program that can,
on some input, use a variable that has not been initialized} is
undecidable. That is, it is not possible to write a program that
will read a C++ program and tell whether there is an input on which
that program will use an uninitialized variable.
Hint. Reduce from the halting problem. Arrange to use
an uninitialized variable just before halting. Be sure that
the program does not use any uninitialized variables before that.
How can you do that?