<?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[Berechnung Intervall mit Grenzen erledigt]]></title><description><![CDATA[<pre><code class="language-cpp">#include &lt;iostream&gt;
using namespace std;

int main()
{
char c;

do{

int oi,ui,zahl;
int x=0,y=0,z=0;

cout&lt;&lt;&quot;Obere Intervallgrenze eingeben&quot;&lt;&lt;endl;
cin&gt;&gt;oi;
cout&lt;&lt;&quot;Untere Intervallgrenze eingeben&quot;&lt;&lt;endl;
cin&gt;&gt;ui;   
do{
cout&lt;&lt;&quot;ZAHLEN EINGEBEN***ENDE ==='0'&quot;&lt;&lt;endl;
cin&gt;&gt;zahl; 

if(zahl&lt;ui)    
        x++;
else if(zahl&gt;ui &amp;&amp; zahl&lt;oi)
        y++;
else if(zahl&gt;oi)
        z++;

}while(zahl!=0);

cout&lt;&lt;&quot;Anzahl Zahlen kleiner als Intervallgrenze=== &quot;&lt;&lt;x&lt;&lt;endl;
cout&lt;&lt;&quot;Anzahl Zahlen im Intervall=== &quot;&lt;&lt;z&lt;&lt;endl;
cout&lt;&lt;&quot;Anzahl Zahlen groesser als Intervallgrenze=== &quot;&lt;&lt;y&lt;&lt;endl;

cout&lt;&lt;&quot;Nochmal==='j'/Abbruch==='n'&quot;&lt;&lt;endl;
cin&gt;&gt;c;

}
while(c=='j');

}
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/topic/290276/berechnung-intervall-mit-grenzen-erledigt</link><generator>RSS for Node</generator><lastBuildDate>Tue, 18 Aug 2026 16:07:57 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/290276.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 22 Jul 2011 17:56:26 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Berechnung Intervall mit Grenzen erledigt on Sat, 23 Jul 2011 12:11:45 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">#include &lt;iostream&gt;
using namespace std;

int main()
{
char c;

do{

int oi,ui,zahl;
int x=0,y=0,z=0;

cout&lt;&lt;&quot;Obere Intervallgrenze eingeben&quot;&lt;&lt;endl;
cin&gt;&gt;oi;
cout&lt;&lt;&quot;Untere Intervallgrenze eingeben&quot;&lt;&lt;endl;
cin&gt;&gt;ui;   
do{
cout&lt;&lt;&quot;ZAHLEN EINGEBEN***ENDE ==='0'&quot;&lt;&lt;endl;
cin&gt;&gt;zahl; 

if(zahl&lt;ui)    
        x++;
else if(zahl&gt;ui &amp;&amp; zahl&lt;oi)
        y++;
else if(zahl&gt;oi)
        z++;

}while(zahl!=0);

cout&lt;&lt;&quot;Anzahl Zahlen kleiner als Intervallgrenze=== &quot;&lt;&lt;x&lt;&lt;endl;
cout&lt;&lt;&quot;Anzahl Zahlen im Intervall=== &quot;&lt;&lt;z&lt;&lt;endl;
cout&lt;&lt;&quot;Anzahl Zahlen groesser als Intervallgrenze=== &quot;&lt;&lt;y&lt;&lt;endl;

cout&lt;&lt;&quot;Nochmal==='j'/Abbruch==='n'&quot;&lt;&lt;endl;
cin&gt;&gt;c;

}
while(c=='j');

}
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/2096651</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2096651</guid><dc:creator><![CDATA[markuswenczel]]></dc:creator><pubDate>Sat, 23 Jul 2011 12:11:45 GMT</pubDate></item><item><title><![CDATA[Reply to Berechnung Intervall mit Grenzen erledigt on Fri, 22 Jul 2011 18:01:06 GMT]]></title><description><![CDATA[<p>deine for()-Schleifen haben keine Abbruchbedingung, das heißt die laufen weiter bis zum St.-Nimmerleinstag. Welchen Sinn sollen diese Schleifen denn überhaupt haben?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2096653</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2096653</guid><dc:creator><![CDATA[CStoll]]></dc:creator><pubDate>Fri, 22 Jul 2011 18:01:06 GMT</pubDate></item><item><title><![CDATA[Reply to Berechnung Intervall mit Grenzen erledigt on Fri, 22 Jul 2011 18:07:49 GMT]]></title><description><![CDATA[<p>CStoll schrieb:</p>
<blockquote>
<p>deine for()-Schleifen haben keine Abbruchbedingung, das heißt die laufen weiter bis zum St.-Nimmerleinstag. Welchen Sinn sollen diese Schleifen denn überhaupt haben?</p>
</blockquote>
<p>die Anzahl zählen wie oft eine Zahl in dem Intervall vorkommt</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2096656</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2096656</guid><dc:creator><![CDATA[markuswenczel]]></dc:creator><pubDate>Fri, 22 Jul 2011 18:07:49 GMT</pubDate></item><item><title><![CDATA[Reply to Berechnung Intervall mit Grenzen erledigt on Fri, 22 Jul 2011 18:13:58 GMT]]></title><description><![CDATA[<p>Jede Zahl, die der Nutzer eingibt, kommt maximal einmal in dem Intervall vor - da brauche ich keine Schleife, um das zu zählen <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /> Ein einfaches <code>if(zahl&lt;ui) ++x;</code> etc. reicht dafür völlig aus.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2096657</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2096657</guid><dc:creator><![CDATA[CStoll]]></dc:creator><pubDate>Fri, 22 Jul 2011 18:13:58 GMT</pubDate></item><item><title><![CDATA[Reply to Berechnung Intervall mit Grenzen erledigt on Sat, 23 Jul 2011 12:11:02 GMT]]></title><description><![CDATA[<p>CStoll schrieb:</p>
<blockquote>
<p>Jede Zahl, die der Nutzer eingibt, kommt maximal einmal in dem Intervall vor - da brauche ich keine Schleife, um das zu zählen <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /> Ein einfaches <code>if(zahl&lt;ui) ++x;</code> etc. reicht dafür völlig aus.</p>
</blockquote>
<p>Ich denke immer noch viel zu kompliziert super danke hat funktioniert</p>
<p><img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f44d.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--thumbs_up"
      title=":+1:"
      alt="👍"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/2096784</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2096784</guid><dc:creator><![CDATA[markuswenczel]]></dc:creator><pubDate>Sat, 23 Jul 2011 12:11:02 GMT</pubDate></item></channel></rss>