<p>PHP has a very nice function, isset($variableName). It checks if $variableName is already defined in the program or not.</p>

<p>Can we build similar feature for C/C++ (some kind of symbol table lookup)?</p>

Not really.  You can't dynamically create variables (though you can dynamically create storage with malloc() et al, or new et al. in C++) in C.  I suppose dynamically loaded libraries blur the picture, but even there, the way you establish whether the variable exists is by looking up its name.  If the name is not there, then, short of running a compiler to create a dynamically loaded module and then loading it, you are probably stuck.  The concept really doesn't apply to C or C++.