title: break doesn't work on pressing enter as input c++
body: <p>I wanted to make the code break on entering the first input in the array but it doesn't work when i press enter key, which means that the program doesn't consider enter as an input</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include &lt;fstream&gt;
  using namespace std;
  char comet[6]={'0'};
  char group[6]={'0'};
  int main()
  {
  for(int i=0;i&lt;6;i++)
  {
      cin&gt;&gt;comet[i];
      break;
  }
  return 0;
  }
  </code></pre>