title: what to do so that I don't cut the string after the space
body: <p>I wrote a program that encrypts a string with the Caesar method. I have a problem when I try to enter a password consisting of several words separated by a space. the code itself works but cuts me off at the time of a space in the string</p>
  <p>i tried to add some ifs but it didn't have any effect, so it only shows working code</p>
  <pre><code>#include &lt;fstream&gt;
  #include &lt;cstdlib&gt;
  #include &lt;string&gt;
  #include &lt;conio.h&gt;
  
  using namespace std;
  
  
  int main() {
      string wynik = &quot;&quot;;
      int i,przesu;
      system(&quot;cls&quot;);
      cout &lt;&lt; &quot;how many shift a password&quot; &lt;&lt; endl;
      cin &gt;&gt; przesu;
      cout &lt;&lt; &quot;your password to encode: &quot;;
      cin &gt;&gt; wynik;
      for (i = 0; i &lt; wynik.length(); i++) {
           if ((int)wynik[i] == 32 ) {
                wynik[i] = wynik[i];
           }
           else {
              wynik[i] = toupper(wynik[i]);
            }
      }
      for (i = 0; i &lt; wynik.length(); i++) {
          if (isupper(wynik[i])) {
              wynik[i] = wynik[i] + przesu;
              if (wynik[i] &gt; 90) {
                  wynik[i] = wynik[i] - 26;
              }
          }
          else {
                  wynik[i] += wynik[i];
         }
          
      }
      cout &lt;&lt; endl &lt;&lt; &quot;your encode password: &quot; &lt;&lt; wynik &lt;&lt; endl;
      cout &lt;&lt; &quot;press any button to continue&quot;;
      _getch();
  }
  </code></pre>