title: online compiler(online gdb)works correctly while g++ and gcc on windows 10 cmd doesn't work when comparing strings
body: <p>When I compare 2 strings in the website &quot;online gdb&quot;, if the comparison is equal it gives 10, if it's not it doesn't give 10(It's already weird that it gives 10 instead of 0, but it works so I didn't care). But since I tried to compile my code with g++ or gcc(I tried with -g too for both)it gives -1 or 1, or only 1, but never 0. Thanks to everyone which will read this code and will help me.</p>
  <pre><code>#include &lt;stdio.h&gt;
  #include &lt;math.h&gt;
  #include &lt;string.h&gt;
  
  int main()
  {
      char v1q[55], v2q[55], v3q[55], v4q[55];
      float v1, v2, v3, v4, vr, min, max;
      int comparison;
      int v3b = 1;
  
  printf(&quot;Per la prima banda non esiste l'oro e l'argento;\nPer la seconda banda non esiste l'oro e l'argento;\nPer la terza banda non esiste il bianco;\nPer la quarta banda esistono SOLO il bianco, oro e argento.\n\n&quot;);
  
  printf(&quot;Prima cifra: &quot;);
  fgets(v1q, sizeof(v1q), stdin);
  
  
  if(strcmp(v1q, &quot;nero&quot;) == 0)
  {
      printf(&quot;\nNon esiste un valore per il nero, per la prima banda&quot;);
  }
  if(strcmp(v1q, &quot;marrone&quot;) == 0)
  {
      v1 = 10;
  }
  if(strcmp(v1q, &quot;rosso&quot;) == 0)
  {
      v1 = 20;
  }
  if(strcmp(v1q, &quot;arancione&quot;) == 0)
  {
      v1 = 30;
  }
  if(strcmp(v1q, &quot;giallo&quot;) == 0)
  {
      v1 = 40;
  }
  if(strcmp(v1q, &quot;verde&quot;) == 0)
  {
      v1 = 50;
  }
  if(strcmp(v1q, &quot;blu&quot;) == 0)
  {
      v1 = 60;
  }
  if(strcmp(v1q, &quot;viola&quot;) == 0)
  {
      v1 = 70;
  }
  if(strcmp(v1q, &quot;grigio&quot;) == 0)
  {
      v1 = 80;
  }
  if(strcmp(v1q, &quot;bianco&quot;) == 0)
  {
      v1 = 90;
  }
  if(strcmp(v1q, &quot;oro&quot;) == 0)
  {
      printf(&quot;\nNon esiste un valore per l'oro, per la prima banda&quot;);
  }
  if(strcmp(v1q, &quot;argento&quot;) == 0)
  {
      printf(&quot;\nNon esiste un valore per l'argento, per la prima banda&quot;);
  }
  comparison = strcmp(v1q, &quot;marrone&quot;);
  printf(&quot;%d&quot;, comparison);
  }
  </code></pre>