<?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[C++ Programm probleme]]></title><description><![CDATA[<p>Hallo</p>
<p>unter dem Text setzte ich den Quellcode meines programmes hin! so funktioniert es auch komplett habe allerdings das Problem das ich eine neue Aufgabenstellung nicht eingearbeitet bekomme! Ich soll die Eingaben in string-Variablen umbauen und der Spieler soll vor dem Spiel die Anzahl an Ziffern vorgeben können!</p>
<p>Ich habe keine ahnung wie ich das Programm umschreiben muss usw.!!</p>
<p>Danke im voraus für jegliche hilfe!!!</p>
<p>Mit freundlichen Grüßen</p>
<p>L.Göbel</p>
<p>hier der bisherige Quellcode:</p>
<p>#include &lt;iostream&gt;<br />
#include &lt;ctime&gt;<br />
#include &lt;string&gt;</p>
<p>using namespace std;</p>
<p>int main()</p>
<p>{</p>
<p>int x = time(NULL), Geschaetztezahl, Zahl, Maximum, Wahl;</p>
<p>do{<br />
cout&lt;&lt;&quot;Wollen sie ein Spiel machen?\n\n&quot;;<br />
cout&lt;&lt;&quot;1 Fuer ein Spiel\n&quot;;<br />
cout&lt;&lt;&quot;2 Beenden des Spiels\n\n&quot;;<br />
cout&lt;&lt;&quot;Ihre Wahl: &quot;;<br />
cin&gt;&gt; Wahl;</p>
<p>if (Wahl==1)<br />
{<br />
cout&lt;&lt;&quot;Bitte geben sie die grosstmoeglichste Zahl an: \n&quot;;<br />
cout&lt;&lt;&quot;Ihr Maximum: &quot;;<br />
cin&gt;&gt;Maximum;</p>
<p>srand(x);</p>
<p>Zahl = rand() % Maximum + 1;</p>
<p>// hier schreiben wenn immer neue Zahl ! / Zahl = rand() % 100 + 1;<br />
cout&lt;&lt; Zahl &lt;&lt;endl;<br />
cout&lt;&lt;&quot;Bitte versuchen sie die Zufallszahl des Computers zu eraten!\n&quot;;</p>
<p>do{<br />
cout&lt;&lt;&quot;Ihre schaetzung: &quot;;<br />
cin&gt;&gt;Geschaetztezahl;</p>
<p>if(Geschaetztezahl&lt;Zahl)<br />
{<br />
cout&lt;&lt;&quot;Ihre Geschaetztezahl zahl war zu niedrig probieren sie es nochmahl\n&quot;;<br />
}<br />
if(Geschaetztezahl&gt;Zahl)<br />
{<br />
cout&lt;&lt;&quot;Ihre Geschaetztezahl zahl war zu hoch probieren sie es nochmahl\n&quot;;<br />
}<br />
if(Geschaetztezahl==Zahl)<br />
{<br />
cout&lt;&lt;&quot;Sie sind Gut!\n\n\n&quot;;<br />
}<br />
}while(Geschaetztezahl&lt;Zahl||Geschaetztezahl&gt;Zahl);<br />
}</p>
<p>if (Wahl==2)<br />
{<br />
cout&lt;&lt;&quot;Das Programm wird beendet!\n\n&quot;; return 0;<br />
}<br />
}while(Wahl==1);</p>
<p>return 0;</p>
<p>}</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/167995/c-programm-probleme</link><generator>RSS for Node</generator><lastBuildDate>Wed, 16 Sep 2026 05:09:26 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/167995.rss" rel="self" type="application/rss+xml"/><pubDate>Sun, 17 Dec 2006 13:31:50 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to C++ Programm probleme on Sun, 17 Dec 2006 13:31:50 GMT]]></title><description><![CDATA[<p>Hallo</p>
<p>unter dem Text setzte ich den Quellcode meines programmes hin! so funktioniert es auch komplett habe allerdings das Problem das ich eine neue Aufgabenstellung nicht eingearbeitet bekomme! Ich soll die Eingaben in string-Variablen umbauen und der Spieler soll vor dem Spiel die Anzahl an Ziffern vorgeben können!</p>
<p>Ich habe keine ahnung wie ich das Programm umschreiben muss usw.!!</p>
<p>Danke im voraus für jegliche hilfe!!!</p>
<p>Mit freundlichen Grüßen</p>
<p>L.Göbel</p>
<p>hier der bisherige Quellcode:</p>
<p>#include &lt;iostream&gt;<br />
#include &lt;ctime&gt;<br />
#include &lt;string&gt;</p>
<p>using namespace std;</p>
<p>int main()</p>
<p>{</p>
<p>int x = time(NULL), Geschaetztezahl, Zahl, Maximum, Wahl;</p>
<p>do{<br />
cout&lt;&lt;&quot;Wollen sie ein Spiel machen?\n\n&quot;;<br />
cout&lt;&lt;&quot;1 Fuer ein Spiel\n&quot;;<br />
cout&lt;&lt;&quot;2 Beenden des Spiels\n\n&quot;;<br />
cout&lt;&lt;&quot;Ihre Wahl: &quot;;<br />
cin&gt;&gt; Wahl;</p>
<p>if (Wahl==1)<br />
{<br />
cout&lt;&lt;&quot;Bitte geben sie die grosstmoeglichste Zahl an: \n&quot;;<br />
cout&lt;&lt;&quot;Ihr Maximum: &quot;;<br />
cin&gt;&gt;Maximum;</p>
<p>srand(x);</p>
<p>Zahl = rand() % Maximum + 1;</p>
<p>// hier schreiben wenn immer neue Zahl ! / Zahl = rand() % 100 + 1;<br />
cout&lt;&lt; Zahl &lt;&lt;endl;<br />
cout&lt;&lt;&quot;Bitte versuchen sie die Zufallszahl des Computers zu eraten!\n&quot;;</p>
<p>do{<br />
cout&lt;&lt;&quot;Ihre schaetzung: &quot;;<br />
cin&gt;&gt;Geschaetztezahl;</p>
<p>if(Geschaetztezahl&lt;Zahl)<br />
{<br />
cout&lt;&lt;&quot;Ihre Geschaetztezahl zahl war zu niedrig probieren sie es nochmahl\n&quot;;<br />
}<br />
if(Geschaetztezahl&gt;Zahl)<br />
{<br />
cout&lt;&lt;&quot;Ihre Geschaetztezahl zahl war zu hoch probieren sie es nochmahl\n&quot;;<br />
}<br />
if(Geschaetztezahl==Zahl)<br />
{<br />
cout&lt;&lt;&quot;Sie sind Gut!\n\n\n&quot;;<br />
}<br />
}while(Geschaetztezahl&lt;Zahl||Geschaetztezahl&gt;Zahl);<br />
}</p>
<p>if (Wahl==2)<br />
{<br />
cout&lt;&lt;&quot;Das Programm wird beendet!\n\n&quot;; return 0;<br />
}<br />
}while(Wahl==1);</p>
<p>return 0;</p>
<p>}</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1193414</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1193414</guid><dc:creator><![CDATA[goebel]]></dc:creator><pubDate>Sun, 17 Dec 2006 13:31:50 GMT</pubDate></item><item><title><![CDATA[Reply to C++ Programm probleme on Sun, 17 Dec 2006 17:43:14 GMT]]></title><description><![CDATA[<p>goebel schrieb:</p>
<blockquote>
<p>Hallo</p>
<p>unter dem Text setzte ich den Quellcode meines programmes hin! so funktioniert es auch komplett habe allerdings das Problem das ich eine neue Aufgabenstellung nicht eingearbeitet bekomme! Ich soll die Eingaben in string-Variablen umbauen und der Spieler soll vor dem Spiel die Anzahl an Ziffern vorgeben können!</p>
<p>Ich habe keine ahnung wie ich das Programm umschreiben muss usw.!!</p>
<p>Danke im voraus für jegliche hilfe!!!</p>
<p>Mit freundlichen Grüßen</p>
<p>L.Göbel</p>
<p>hier der bisherige Quellcode:</p>
<pre><code class="language-cpp">#include &lt;iostream&gt;
#include &lt;ctime&gt;
#include &lt;string&gt;

using namespace std;

int main()

{
	
	int x = time(NULL), Geschaetztezahl, Zahl, Maximum, Wahl;

	do{
		cout&lt;&lt;&quot;Wollen sie ein Spiel machen?\n\n&quot;;
		cout&lt;&lt;&quot;1 Fuer ein Spiel\n&quot;;
		cout&lt;&lt;&quot;2 Beenden des Spiels\n\n&quot;;
		cout&lt;&lt;&quot;Ihre Wahl: &quot;;
		cin&gt;&gt; Wahl;

		if (Wahl==1)
		{
			cout&lt;&lt;&quot;Bitte geben sie die grosstmoeglichste Zahl an: \n&quot;;
			cout&lt;&lt;&quot;Ihr Maximum: &quot;;
			cin&gt;&gt;Maximum;

			srand(x);
	
			Zahl = rand() % Maximum + 1;

			// hier schreiben wenn immer neue Zahl ! / Zahl = rand() % 100 + 1;
			cout&lt;&lt; Zahl &lt;&lt;endl;
			cout&lt;&lt;&quot;Bitte versuchen sie die Zufallszahl des Computers zu eraten!\n&quot;;

		do{
			cout&lt;&lt;&quot;Ihre schaetzung: &quot;;
			cin&gt;&gt;Geschaetztezahl;

			
		
			if(Geschaetztezahl&lt;Zahl)
			{
				cout&lt;&lt;&quot;Ihre Geschaetztezahl zahl war zu niedrig probieren sie es nochmahl\n&quot;;
			}
			if(Geschaetztezahl&gt;Zahl)
			{
				cout&lt;&lt;&quot;Ihre Geschaetztezahl zahl war zu hoch probieren sie es nochmahl\n&quot;;
			}
			if(Geschaetztezahl==Zahl)
			{
				cout&lt;&lt;&quot;Sie sind Gut!\n\n\n&quot;;
			}
		}while(Geschaetztezahl&lt;Zahl||Geschaetztezahl&gt;Zahl);
	}

		if (Wahl==2)
			{
				cout&lt;&lt;&quot;Das Programm wird beendet!\n\n&quot;; return 0;
			}
	}while(Wahl==1);

return 0;
</code></pre>
<p>}</p>
</blockquote>
]]></description><link>https://www.c-plusplus.net/forum/post/1193592</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1193592</guid><dc:creator><![CDATA[formater]]></dc:creator><pubDate>Sun, 17 Dec 2006 17:43:14 GMT</pubDate></item><item><title><![CDATA[Reply to C++ Programm probleme on Sun, 17 Dec 2006 18:52:58 GMT]]></title><description><![CDATA[<p>Nimm die Unterlagen die Du in der Schule bekommen hast und lies die mal</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1193621</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1193621</guid><dc:creator><![CDATA[Knuddlbaer]]></dc:creator><pubDate>Sun, 17 Dec 2006 18:52:58 GMT</pubDate></item></channel></rss>