Check out example codes for "how to make a debug in c". It will help you in understanding the concepts better.

Code Example 1

#include <stdio.h>

#define DEBUG 1 // Set to 0 for no debug

#if DEBUG // check if debug is 1

#define LOG(X) printf(X) // define log as printf

#else // if debug not 1

#DEFINE LOG(X) // define log as nothing

#endif // end

void main(void) {
  	LOG("Hello, Debug!\n");
	printf("Hello, World!\n");

Learn ReactJs, React Native from