<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: C++ Standard I/O and strings</title>
	<atom:link href="http://www.codingunit.com/cplusplus-tutorial-standard-io-and-strings/feed" rel="self" type="application/rss+xml" />
	<link>http://www.codingunit.com/cplusplus-tutorial-standard-io-and-strings</link>
	<description>CodingUnit is your online resource for learning to program. Tutorials on C, C++, PHP, Python, MySQL, Java, JQuery, Opengl, DirectX and much more!</description>
	<lastBuildDate>Mon, 06 Feb 2012 06:08:16 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
	<item>
		<title>By: admin</title>
		<link>http://www.codingunit.com/cplusplus-tutorial-standard-io-and-strings/comment-page-1#comment-1072</link>
		<dc:creator>admin</dc:creator>
		<pubDate>Tue, 29 Jun 2010 16:15:48 +0000</pubDate>
		<guid isPermaLink="false">http://localhost/?p=491#comment-1072</guid>
		<description>@jim  
Appending (joining) strings isn&#039;t that hard. Maybe that the example confuses you, so take another look at the following example:


#include&lt;iostream&gt;
#include&lt;string&gt;

using namespace std;

void main(void){

	string a;
	string b;
	string output;
        
        // Fill the two strings
	a = &quot;Hello&quot;;
	b = &quot; World!&quot;;

	// Normal append of two strings
	output = a + b;
	cout &lt;&lt; output &lt;&lt; endl;

	// Or without the output string variable
	cout &lt;&lt; (a + b) &lt;&lt; endl;

	// Using compound assignments += operator
	output = a; 
	output += b;  
	// In fact you are saying output = output + b;
	// So if you fill the string variables you get:
	// Hello + World! = result in output.
	cout &lt;&lt; output &lt;&lt; endl;
}

I hope that this joining strings example is somewhat easier to understand.</description>
		<content:encoded><![CDATA[<p>@jim<br />
Appending (joining) strings isn&#8217;t that hard. Maybe that the example confuses you, so take another look at the following example:</p>
<p>#include&lt;iostream&gt;<br />
#include&lt;string&gt;</p>
<p>using namespace std;</p>
<p>void main(void){</p>
<p>	string a;<br />
	string b;<br />
	string output;</p>
<p>        // Fill the two strings<br />
	a = &#8220;Hello&#8221;;<br />
	b = &#8221; World!&#8221;;</p>
<p>	// Normal append of two strings<br />
	output = a + b;<br />
	cout &lt;&lt; output &lt;&lt; endl;</p>
<p>	// Or without the output string variable<br />
	cout &lt;&lt; (a + b) &lt;&lt; endl;</p>
<p>	// Using compound assignments += operator<br />
	output = a;<br />
	output += b;<br />
	// In fact you are saying output = output + b;<br />
	// So if you fill the string variables you get:<br />
	// Hello + World! = result in output.<br />
	cout &lt;&lt; output &lt;&lt; endl;<br />
}</p>
<p>I hope that this joining strings example is somewhat easier to understand.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: jim</title>
		<link>http://www.codingunit.com/cplusplus-tutorial-standard-io-and-strings/comment-page-1#comment-999</link>
		<dc:creator>jim</dc:creator>
		<pubDate>Fri, 25 Jun 2010 01:35:39 +0000</pubDate>
		<guid isPermaLink="false">http://localhost/?p=491#comment-999</guid>
		<description>the joining strings is really confusing</description>
		<content:encoded><![CDATA[<p>the joining strings is really confusing</p>
]]></content:encoded>
	</item>
</channel>
</rss>

