title: std::cin - can you have one input put into two different variables?
body: <p>Hi I am trying to read input from the user once and then pass this value into two different types of variables is this possible? </p>
  
  <p>I need the value to be passed into an integer variable which is required for calculations and also a string so I can add the data to the formatted date which is a string variable.</p>
  
  <p>Here is he code which I have tried which doesn't work.</p>
  
  <pre><code>cin &gt;&gt; daymonth,dayofmonth;
  </code></pre>
  
  <p>Any help would be greatly appreciated, I am programming in OOP if this is of any relevance.</p>