<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[In einem std::string &amp;quot;&#x5C;n&amp;quot; durch &amp;quot;&#x5C;r&#x5C;n&amp;quot; ersetzen?]]></title><description><![CDATA[<p>Hallo,</p>
<p>die Standardlibrary treibt mich mal wieder in den Wahnsinn. Ich habe es schon mit <code>std::replace</code> sowie <code>std::string::replace</code> versucht, jedoch bin ich auf keine Lösung gekommen, ohne dass mir der Compiler Fehler gemeldet hat.</p>
<p>Deshalb meine Frage: wie kann ich in einem <code>std::string</code> alle <code>&quot;\n&quot;</code> durch <code>&quot;\r\n&quot;</code> ersetzen?</p>
<p>(Möglichst eine Lösung mit Algorithmen aus der Standardlibrary, mit einer <code>for</code> -Schleife könnte ich es auch lösen, aber das ist nicht das Gelbe vom Ei)</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/212152/in-einem-std-string-quot-n-quot-durch-quot-r-n-quot-ersetzen</link><generator>RSS for Node</generator><lastBuildDate>Wed, 14 Oct 2026 16:00:39 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/212152.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 02 May 2008 14:23:15 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to In einem std::string &amp;quot;&#x5C;n&amp;quot; durch &amp;quot;&#x5C;r&#x5C;n&amp;quot; ersetzen? on Fri, 02 May 2008 14:25:09 GMT]]></title><description><![CDATA[<p>Hallo,</p>
<p>die Standardlibrary treibt mich mal wieder in den Wahnsinn. Ich habe es schon mit <code>std::replace</code> sowie <code>std::string::replace</code> versucht, jedoch bin ich auf keine Lösung gekommen, ohne dass mir der Compiler Fehler gemeldet hat.</p>
<p>Deshalb meine Frage: wie kann ich in einem <code>std::string</code> alle <code>&quot;\n&quot;</code> durch <code>&quot;\r\n&quot;</code> ersetzen?</p>
<p>(Möglichst eine Lösung mit Algorithmen aus der Standardlibrary, mit einer <code>for</code> -Schleife könnte ich es auch lösen, aber das ist nicht das Gelbe vom Ei)</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1502116</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1502116</guid><dc:creator><![CDATA[CodeOriginator]]></dc:creator><pubDate>Fri, 02 May 2008 14:25:09 GMT</pubDate></item><item><title><![CDATA[Reply to In einem std::string &amp;quot;&#x5C;n&amp;quot; durch &amp;quot;&#x5C;r&#x5C;n&amp;quot; ersetzen? on Fri, 02 May 2008 14:28:04 GMT]]></title><description><![CDATA[<p>Hier findest du eine replace_all Funktion: <a href="http://c-plusplus.net/forum/viewtopic-var-t-is-155739.html" rel="nofollow">http://c-plusplus.net/forum/viewtopic-var-t-is-155739.html</a></p>
]]></description><link>https://www.c-plusplus.net/forum/post/1502123</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1502123</guid><dc:creator><![CDATA[123]]></dc:creator><pubDate>Fri, 02 May 2008 14:28:04 GMT</pubDate></item><item><title><![CDATA[Reply to In einem std::string &amp;quot;&#x5C;n&amp;quot; durch &amp;quot;&#x5C;r&#x5C;n&amp;quot; ersetzen? on Fri, 02 May 2008 14:33:31 GMT]]></title><description><![CDATA[<p>Merci, kumplé. Wusste nicht, dass man sich diese Lösung selber zusammen frickeln muss. <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f642.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--slightly_smiling_face"
      title=":)"
      alt="🙂"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/1502131</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1502131</guid><dc:creator><![CDATA[CodeOriginator]]></dc:creator><pubDate>Fri, 02 May 2008 14:33:31 GMT</pubDate></item><item><title><![CDATA[Reply to In einem std::string &amp;quot;&#x5C;n&amp;quot; durch &amp;quot;&#x5C;r&#x5C;n&amp;quot; ersetzen? on Fri, 02 May 2008 14:37:39 GMT]]></title><description><![CDATA[<p>Das ist ja das tolle am std::string, dass jeder immer wieder alles neu schreiben muss....</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1502137</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1502137</guid><dc:creator><![CDATA[hahahahu]]></dc:creator><pubDate>Fri, 02 May 2008 14:37:39 GMT</pubDate></item><item><title><![CDATA[Reply to In einem std::string &amp;quot;&#x5C;n&amp;quot; durch &amp;quot;&#x5C;r&#x5C;n&amp;quot; ersetzen? on Fri, 02 May 2008 14:41:56 GMT]]></title><description><![CDATA[<p>hahahahu schrieb:</p>
<blockquote>
<p>Das ist ja das tolle am std::string, dass jeder immer wieder alles neu schreiben muss....</p>
</blockquote>
<p>noob</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1502143</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1502143</guid><dc:creator><![CDATA[ps]]></dc:creator><pubDate>Fri, 02 May 2008 14:41:56 GMT</pubDate></item><item><title><![CDATA[Reply to In einem std::string &amp;quot;&#x5C;n&amp;quot; durch &amp;quot;&#x5C;r&#x5C;n&amp;quot; ersetzen? on Fri, 02 May 2008 14:46:27 GMT]]></title><description><![CDATA[<p>ps schrieb:</p>
<blockquote>
<p>hahahahu schrieb:</p>
<blockquote>
<p>Das ist ja das tolle am std::string, dass jeder immer wieder alles neu schreiben muss....</p>
</blockquote>
<p>noob</p>
</blockquote>
<p>Begründung?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1502144</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1502144</guid><dc:creator><![CDATA[hahahahu]]></dc:creator><pubDate>Fri, 02 May 2008 14:46:27 GMT</pubDate></item><item><title><![CDATA[Reply to In einem std::string &amp;quot;&#x5C;n&amp;quot; durch &amp;quot;&#x5C;r&#x5C;n&amp;quot; ersetzen? on Fri, 02 May 2008 14:47:07 GMT]]></title><description><![CDATA[<p>ps schrieb:</p>
<blockquote>
<p>hahahahu schrieb:</p>
<blockquote>
<p>Das ist ja das tolle am std::string, dass jeder immer wieder alles neu schreiben muss....</p>
</blockquote>
<p>noob</p>
</blockquote>
<p>pro</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1502145</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1502145</guid><dc:creator><![CDATA[ps]]></dc:creator><pubDate>Fri, 02 May 2008 14:47:07 GMT</pubDate></item></channel></rss>