title: What is the purpose of using -pedantic in the GCC/G++ compiler?
body: <p><a href="http://web.mit.edu/10.001/Web/Tips/tips_on_gcc.html" rel="noreferrer">This note</a> says:</p>
  <blockquote>
  <p><a href="https://gcc.gnu.org/onlinedocs/gcc/C-Dialect-Options.html#index-ANSI-support" rel="noreferrer"><code>-ansi</code></a>: tells the compiler to implement the ANSI language option. This turns
  off certain &quot;features&quot; of GCC which
  are incompatible with the ANSI
  standard.</p>
  <p><a href="https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html#index-pedantic-1" rel="noreferrer"><code>-pedantic</code></a>: used in conjunction with <code>-ansi</code>, this tells the compiler to be adhere strictly to the ANSI standard,
  rejecting any code which is not
  compliant.</p>
  </blockquote>
  <p>First things first:</p>
  <ul>
  <li>What is the purpose of the <code>-pedantic</code> and <code>-ansi</code> options of the GCC/G++ compiler (I couldn't understand the above description)?</li>
  <li>What are the right circumstances for using these two options?</li>
  <li>When should I use them?</li>
  <li>Are they important?</li>
  </ul>