Check out example codes for "Unity if object doens't exist". It will help you in understanding the concepts better.

Code Example 1

if(!Object) //If GameObject doesn't exist (! == not)
{
	//Do Something
}

Learn ReactJs, React Native from akashmittal.com