<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="FeedCreator 1.8" -->
<?xml-stylesheet href="https://pflebit.de/lib/exe/css.php?s=feed" type="text/css"?>
<rss version="2.0">
    <channel xmlns:g="http://base.google.com/ns/1.0">
        <title>PflebIT - Pflegeinformatik in der Praxis - kb:software:python</title>
        <description></description>
        <link>https://pflebit.de/</link>
        <lastBuildDate>Mon, 20 Apr 2026 21:16:16 +0000</lastBuildDate>
        <generator>FeedCreator 1.8</generator>
        <image>
            <url>https://pflebit.de/lib/exe/fetch.php?media=wiki:logo.png</url>
            <title>PflebIT - Pflegeinformatik in der Praxis</title>
            <link>https://pflebit.de/</link>
        </image>
        <item>
            <title>For-Schleifen</title>
            <link>https://pflebit.de/doku.php?id=kb:software:python:forschleifen</link>
            <description>
&lt;h1 class=&quot;sectionedit1&quot; id=&quot;for-schleifen&quot;&gt;For-Schleifen&lt;/h1&gt;
&lt;div class=&quot;level1&quot;&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;For-Schleifen&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;for-schleifen&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:1,&amp;quot;range&amp;quot;:&amp;quot;1-30&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit2&quot; id=&quot;elemente_einer_liste_mit_for_ausgeben&quot;&gt;Elemente einer Liste mit for ausgeben&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Geben Sie alle Elemente einer Liste in jeweils einer neuen Zeile aus:
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;for&lt;/span&gt; marke &lt;span class=&quot;kw1&quot;&gt;in&lt;/span&gt; automarke:
	&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;marke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;opel
vw
dacia
mercedes
porsche
fiat&lt;/pre&gt;

&lt;p&gt;
Hinweis: Alle Befehle die innerhalb der for-Schleife ausgeführt werden sollen, müssen eingerückt sein.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Elemente einer Liste mit for ausgeben&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;elemente_einer_liste_mit_for_ausgeben&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:2,&amp;quot;range&amp;quot;:&amp;quot;31-&amp;quot;} --&gt;</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Thu, 30 Jul 2020 13:00:31 +0000</pubDate>
        </item>
        <item>
            <title>Listen</title>
            <link>https://pflebit.de/doku.php?id=kb:software:python:listen</link>
            <description>
&lt;h1 class=&quot;sectionedit1&quot; id=&quot;listen&quot;&gt;Listen&lt;/h1&gt;
&lt;div class=&quot;level1&quot;&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Listen&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;listen&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:1,&amp;quot;range&amp;quot;:&amp;quot;1-22&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit2&quot; id=&quot;elemente_in_liste_anlegen_und_aufrufen&quot;&gt;Elemente in Liste anlegen und aufrufen&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
automarke.&lt;span class=&quot;me1&quot;&gt;append&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarke.&lt;span class=&quot;me1&quot;&gt;append&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarke.&lt;span class=&quot;me1&quot;&gt;append&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarke.&lt;span class=&quot;me1&quot;&gt;append&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Elemente in Liste anlegen und aufrufen&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;elemente_in_liste_anlegen_und_aufrufen&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:2,&amp;quot;range&amp;quot;:&amp;quot;23-230&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit3&quot; id=&quot;element_aufrufen&quot;&gt;Element aufrufen&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Der Abruf der Elemente erfolgt mittels Index, der in eckigen Klammern angegeben wird. Der erste Wert wird mit einer 0 (Null) aufgerufen, der zweite Wert mit einer 1 etc.
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;nu0&quot;&gt;0&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;nu0&quot;&gt;4&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Man kann die Liste auch von hinten abfragen (also rückwärts). In diesem Fall wird der erste Wert mit einer -1 aufgerufen, der zweite Wert (von hinten) mit einer -2.
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;-&lt;span class=&quot;nu0&quot;&gt;1&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;-&lt;span class=&quot;nu0&quot;&gt;3&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Element aufrufen&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;element_aufrufen&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:1,&amp;quot;secid&amp;quot;:3,&amp;quot;range&amp;quot;:&amp;quot;231-877&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit4&quot; id=&quot;element_aendern_change&quot;&gt;Element ändern (change)&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarke&lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;nu0&quot;&gt;1&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt; &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;renault&#039;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ändert das zweite Element &amp;#039;vw&amp;#039; in &amp;#039;renault&amp;#039; um.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Element \u00e4ndern (change)&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;element_aendern_change&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:3,&amp;quot;secid&amp;quot;:4,&amp;quot;range&amp;quot;:&amp;quot;878-1113&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit5&quot; id=&quot;element_hinzufuegenam_ende_add&quot;&gt;Element hinzufügen: am Ende (add)&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarke.&lt;span class=&quot;me1&quot;&gt;append&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;skoda&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Fügt das Element &amp;#039;skoda&amp;#039; am Ende der Liste an.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Element hinzuf\u00fcgen: am Ende (add)&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;element_hinzufuegenam_ende_add&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:4,&amp;quot;secid&amp;quot;:5,&amp;quot;range&amp;quot;:&amp;quot;1114-1358&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit6&quot; id=&quot;element_hinzufuegenan_bestimmter_stelle_insert&quot;&gt;Element hinzufügen: an bestimmter Stelle (insert)&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarke.&lt;span class=&quot;me1&quot;&gt;insert&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;nu0&quot;&gt;1&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;skoda&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Fügt das Element &amp;#039;skoda&amp;#039; an der zweiten Stelle (also nach &amp;#039;opel&amp;#039; und vor &amp;#039;vw&amp;#039;) der Liste ein.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Element hinzuf\u00fcgen: an bestimmter Stelle (insert)&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;element_hinzufuegenan_bestimmter_stelle_insert&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:5,&amp;quot;secid&amp;quot;:6,&amp;quot;range&amp;quot;:&amp;quot;1359-1670&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit7&quot; id=&quot;element_loeschen_mit_del&quot;&gt;Element löschen mit (del)&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Mit del können Elemente gelöscht werden. Im Gegensatz zu pop kann del jedoch den gelöschten Wert nicht zurückgeben (er kann also nicht weiter verwendet werden).
&lt;/p&gt;

&lt;p&gt;
Element an der zweiten Stelle soll gelöscht werden:
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;del&lt;/span&gt; automarke&lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;nu0&quot;&gt;1&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
[&amp;#039;opel&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]&lt;/pre&gt;

&lt;p&gt;
Die ersten drei Elemente sollen gelöscht werden:
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;del&lt;/span&gt; automarke&lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;nu0&quot;&gt;0&lt;/span&gt;:&lt;span class=&quot;nu0&quot;&gt;3&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
[&amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]&lt;/pre&gt;

&lt;p&gt;
Alle Elemente sollen gelöscht werden:
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;del&lt;/span&gt; automarke&lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;:&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
[&amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]&lt;/pre&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Element l\u00f6schen mit (del)&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;element_loeschen_mit_del&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:6,&amp;quot;secid&amp;quot;:7,&amp;quot;range&amp;quot;:&amp;quot;1671-2808&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit8&quot; id=&quot;element_loeschen_mit_pop_und_weiter_verwenden&quot;&gt;Element löschen mit (pop) und weiter verwenden&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Element am Ende der Liste löschen und weiter verwenden:
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarkeeinzelteil &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; automarke.&lt;span class=&quot;me1&quot;&gt;pop&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarkeeinzelteil&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;]
fiat&lt;/pre&gt;

&lt;p&gt;
Element an einer bestimmten Stelle löschen (drittes Element):
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarkeeinzelteil &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; automarke.&lt;span class=&quot;me1&quot;&gt;pop&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;nu0&quot;&gt;2&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarkeeinzelteil&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
dacia&lt;/pre&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Element l\u00f6schen mit (pop) und weiter verwenden&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;element_loeschen_mit_pop_und_weiter_verwenden&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:12,&amp;quot;secid&amp;quot;:8,&amp;quot;range&amp;quot;:&amp;quot;2809-3640&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit9&quot; id=&quot;element_loeschen_mit_remove&quot;&gt;Element löschen mit (remove)&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Im Gegensatz zu del und pop kann die remove-Methode einen Wert löschen, in der der Wert selbst angegeben wird und nicht der Index des Wertes. Der mit dieser Methode gelöschte Wert kann nicht mehr weiterverwendet werden. Deshalb steht am Ende der Beispielausgabe ein „None“:
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarkeeinzelteil &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; automarke.&lt;span class=&quot;me1&quot;&gt;remove&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarkeeinzelteil&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
None&lt;/pre&gt;

&lt;p&gt;
Sofern sich der Wert in der Liste mehrfach befindet, löscht die remove-Methode nur den ersten Wert. Sollen alle gleichlautenden Werte in der Liste gelöscht werden, so muss hierfür eine Schleife verwendet werden.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Element l\u00f6schen mit (remove)&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;element_loeschen_mit_remove&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:16,&amp;quot;secid&amp;quot;:9,&amp;quot;range&amp;quot;:&amp;quot;3641-4508&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit10&quot; id=&quot;element_sortieren_a-z_mit_sort_-_permanente_sortierung&quot;&gt;Element sortieren a-z mit (sort) - permanente Sortierung&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Der sort-Befehl sortiert eine unsortierte Liste von a bis z. Verwendet man den Parameter „reverse=True“, wird die Liste von z bis a sortiert. In beiden Fällen bleibt die Sortierung für die Zukunft bestehen (d.h. die Variable wird tatsächlich geändert):
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarke.&lt;span class=&quot;me1&quot;&gt;sort&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarke.&lt;span class=&quot;me1&quot;&gt;sort&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;reverse&lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;kw2&quot;&gt;True&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
[&amp;#039;dacia&amp;#039;, &amp;#039;fiat&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;opel&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;vw&amp;#039;]
[&amp;#039;vw&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;opel&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;fiat&amp;#039;, &amp;#039;dacia&amp;#039;]&lt;/pre&gt;

&lt;p&gt;
Hinweis: Die Groß- und Kleinschreibung wird bei der Sortierung berücksichtigt.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Element sortieren a-z mit (sort) - permanente Sortierung&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;element_sortieren_a-z_mit_sort_-_permanente_sortierung&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:18,&amp;quot;secid&amp;quot;:10,&amp;quot;range&amp;quot;:&amp;quot;4509-5297&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit11&quot; id=&quot;element_sortieren_a-z_mit_sorted_-_nicht-permanente_sortierung&quot;&gt;Element sortieren a-z mit (sorted) - nicht-permanente Sortierung&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Der sorted-Befehl sortiert eine unsortierte Liste von a bis z. Verwendet man den Parameter „reverse=True“, wird die Liste von z bis a sortiert. In beiden Fällen gilt die Sortierung jedoch nur für „eine“ Ausgabe der Liste. D.h. die Variable wird „nicht“ in ihrer Sortierung geändert). Mit dem Zusatzparameter „reverse=True“ kann die Reihenfolge umgekehrt werden.
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;kw2&quot;&gt;sorted&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;kw2&quot;&gt;sorted&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; reverse&lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;kw2&quot;&gt;True&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
[&amp;#039;dacia&amp;#039;, &amp;#039;fiat&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;opel&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;vw&amp;#039;]
[&amp;#039;vw&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;opel&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;fiat&amp;#039;, &amp;#039;dacia&amp;#039;]
[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]&lt;/pre&gt;

&lt;p&gt;
Hinweis: Der Parameter „True“ muss mit einem großen T beginnen.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Element sortieren a-z mit (sorted) - nicht-permanente Sortierung&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;element_sortieren_a-z_mit_sorted_-_nicht-permanente_sortierung&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:20,&amp;quot;secid&amp;quot;:11,&amp;quot;range&amp;quot;:&amp;quot;5298-6242&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit12&quot; id=&quot;element_sortieren_umgekehrte_reihenfolge_mit_reverse_-_permanent&quot;&gt;Element sortieren umgekehrte Reihenfolge mit (reverse) - permanent&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Der reverse-Befehl dreht die Reihenfolge der Elemente einer Liste um (es wird also nicht sortiert). Ein erneuter Aufruf des Befehls stellt den Ausgangszustand wieder her:
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarke.&lt;span class=&quot;me1&quot;&gt;reverse&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
automarke.&lt;span class=&quot;me1&quot;&gt;reverse&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
[&amp;#039;fiat&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;opel&amp;#039;]
[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]&lt;/pre&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Element sortieren umgekehrte Reihenfolge mit (reverse) - permanent&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;element_sortieren_umgekehrte_reihenfolge_mit_reverse_-_permanent&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:22,&amp;quot;secid&amp;quot;:12,&amp;quot;range&amp;quot;:&amp;quot;6243-6867&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit13&quot; id=&quot;anzahl_der_elemente_einer_liste_ausgeben&quot;&gt;Anzahl der Elemente einer Liste ausgeben&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Um die Anzahl der Elemente einer Liste auszugeben, verwenden Sie den len-Befehl:
&lt;/p&gt;
&lt;pre class=&quot;code python&quot;&gt;automarke &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#91;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;opel&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;vw&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;dacia&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;mercedes&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;porsche&#039;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&#039;fiat&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#93;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;kw2&quot;&gt;len&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;automarke&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;[&amp;#039;opel&amp;#039;, &amp;#039;vw&amp;#039;, &amp;#039;dacia&amp;#039;, &amp;#039;mercedes&amp;#039;, &amp;#039;porsche&amp;#039;, &amp;#039;fiat&amp;#039;]
6&lt;/pre&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Anzahl der Elemente einer Liste ausgeben&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;anzahl_der_elemente_einer_liste_ausgeben&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:24,&amp;quot;secid&amp;quot;:13,&amp;quot;range&amp;quot;:&amp;quot;6868-&amp;quot;} --&gt;</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Thu, 30 Jul 2020 12:57:42 +0000</pubDate>
        </item>
        <item>
            <title>Graphical User Interface (GUI)</title>
            <link>https://pflebit.de/doku.php?id=kb:software:python:sonstiges-gui</link>
            <description>
&lt;h1 class=&quot;sectionedit1&quot; id=&quot;graphical_user_interface_gui&quot;&gt;Graphical User Interface (GUI)&lt;/h1&gt;
&lt;div class=&quot;level1&quot;&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Graphical User Interface (GUI)&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;graphical_user_interface_gui&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:1,&amp;quot;range&amp;quot;:&amp;quot;1-46&amp;quot;} --&gt;
&lt;h2 class=&quot;sectionedit2&quot; id=&quot;welche_grafischen_oberflaechen_-_graphical_user_interface_gui_-_gibt_es_fuer_python&quot;&gt;Welche Grafischen Oberflächen - Graphical User Interface (GUI) - gibt es für Python?&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

&lt;p&gt;
&lt;strong&gt;Kivy&lt;/strong&gt;&lt;br/&gt;

&lt;a href=&quot;https://kivy.org/doc/stable/&quot; class=&quot;urlextern&quot; title=&quot;https://kivy.org/doc/stable/&quot; rel=&quot;ugc nofollow&quot;&gt;Kivy - Dokumentation und API&lt;/a&gt;&lt;br/&gt;

Besonders gut: Hiermit kann man Android-Apps auf Python-Basis erstellen.
&lt;/p&gt;

&lt;p&gt;
&lt;strong&gt;PyGTK&lt;/strong&gt;&lt;br/&gt;

Besonders gut: Linux verwendet auch GTK, so dass die Grafikelemente besonders gut für Linux geeignet sind.&lt;br/&gt;

&lt;/p&gt;

&lt;p&gt;
&lt;strong&gt;PyQT / PySide&lt;/strong&gt;&lt;br/&gt;

Besonders gut: Hat sehr viele und komplexe Widgets.
&lt;/p&gt;

&lt;p&gt;
&lt;strong&gt;TKinter&lt;/strong&gt;&lt;br/&gt;

Empfehlung 2018 &lt;img src=&quot;https://pflebit.de/lib/images/smileys/exclaim.svg&quot; class=&quot;icon smiley&quot; alt=&quot;:!:&quot; /&gt; Besonders gut: Einfaches und kleines Programm.
&lt;/p&gt;

&lt;p&gt;
&lt;strong&gt;wxPython&lt;/strong&gt;&lt;br/&gt;

Besonders gut: Hat sehr viele und komplexe Widgets. Ist auch für kommerziellen Gebrauch kostenlos.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Welche Grafischen Oberfl\u00e4chen - Graphical User Interface (GUI) - gibt es f\u00fcr Python?&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;welche_grafischen_oberflaechen_-_graphical_user_interface_gui_-_gibt_es_fuer_python&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:2,&amp;quot;range&amp;quot;:&amp;quot;47-&amp;quot;} --&gt;</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Mon, 26 Dec 2022 15:35:08 +0000</pubDate>
        </item>
        <item>
            <title>SQLite</title>
            <link>https://pflebit.de/doku.php?id=kb:software:python:sqlite</link>
            <description>
&lt;h1 class=&quot;sectionedit1&quot; id=&quot;sqlite&quot;&gt;SQLite&lt;/h1&gt;
&lt;div class=&quot;level1&quot;&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;SQLite&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;sqlite&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:1,&amp;quot;range&amp;quot;:&amp;quot;1-23&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit2&quot; id=&quot;datenbank_per_python_erzeugen&quot;&gt;Datenbank per Python erzeugen&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;pre class=&quot;code python&quot;&gt;&lt;span class=&quot;co1&quot;&gt;# Quelle: https://pynative.com/python-sqlite/&lt;/span&gt;
&amp;nbsp;
&lt;span class=&quot;kw1&quot;&gt;import&lt;/span&gt; sqlite3
&amp;nbsp;
&lt;span class=&quot;kw1&quot;&gt;try&lt;/span&gt;:
    sqliteConnection &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; sqlite3.&lt;span class=&quot;me1&quot;&gt;connect&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;SQLite_Python.db&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
    cursor &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; sqliteConnection.&lt;span class=&quot;me1&quot;&gt;cursor&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
    &lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&amp;quot;Database created and Successfully Connected to SQLite&amp;quot;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&amp;nbsp;
    sqlite_select_Query &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&amp;quot;select sqlite_version();&amp;quot;&lt;/span&gt;
    cursor.&lt;span class=&quot;me1&quot;&gt;execute&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;sqlite_select_Query&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
    record &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; cursor.&lt;span class=&quot;me1&quot;&gt;fetchall&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
    &lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&amp;quot;SQLite Database Version is: &amp;quot;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; record&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
    cursor.&lt;span class=&quot;me1&quot;&gt;close&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&amp;nbsp;
&lt;span class=&quot;kw1&quot;&gt;except&lt;/span&gt; sqlite3.&lt;span class=&quot;me1&quot;&gt;Error&lt;/span&gt; &lt;span class=&quot;kw1&quot;&gt;as&lt;/span&gt; error:
    &lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&amp;quot;Error while connecting to sqlite&amp;quot;&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;,&lt;/span&gt; error&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;finally&lt;/span&gt;:
    &lt;span class=&quot;kw1&quot;&gt;if&lt;/span&gt; &lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;sqliteConnection&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;:
        sqliteConnection.&lt;span class=&quot;me1&quot;&gt;close&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
        &lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&amp;quot;The SQLite connection is closed&amp;quot;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;Database created and Successfully Connected to SQLite
SQLite Database Version is:  [(&amp;#039;3.31.1&amp;#039;,)]
The SQLite connection is closed&lt;/pre&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Datenbank per Python erzeugen&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;datenbank_per_python_erzeugen&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:2,&amp;quot;range&amp;quot;:&amp;quot;24-876&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit3&quot; id=&quot;struktur_nicht_inhalt_einer_tabelle_anzeigen&quot;&gt;Struktur (nicht Inhalt) einer Tabelle anzeigen&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;pre class=&quot;code python&quot;&gt;&lt;span class=&quot;co1&quot;&gt;# Beispiel-Datenbank von https://www.sqlitetutorial.net/sqlite-sample-database/&lt;/span&gt;
&amp;nbsp;
&lt;span class=&quot;kw1&quot;&gt;import&lt;/span&gt; sqlite3
&amp;nbsp;
sqliteConnection &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; sqlite3.&lt;span class=&quot;me1&quot;&gt;connect&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;chinook.db&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
cursor &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; sqliteConnection.&lt;span class=&quot;me1&quot;&gt;cursor&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&amp;quot;Database created and Successfully Connected to SQLite&amp;quot;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&amp;nbsp;
cursor.&lt;span class=&quot;me1&quot;&gt;execute&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&amp;quot;PRAGMA table_info(`albums`)&amp;quot;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;for&lt;/span&gt; column &lt;span class=&quot;kw1&quot;&gt;in&lt;/span&gt; cursor:
    &lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;column&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
cursor.&lt;span class=&quot;me1&quot;&gt;close&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&amp;nbsp;
sqliteConnection.&lt;span class=&quot;me1&quot;&gt;close&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&amp;quot;The SQLite connection is closed&amp;quot;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;Database created and Successfully Connected to SQLite
(0, &amp;#039;AlbumId&amp;#039;, &amp;#039;INTEGER&amp;#039;, 1, None, 1)
(1, &amp;#039;Title&amp;#039;, &amp;#039;NVARCHAR(160)&amp;#039;, 1, None, 0)
(2, &amp;#039;ArtistId&amp;#039;, &amp;#039;INTEGER&amp;#039;, 1, None, 0)
The SQLite connection is closed&lt;/pre&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Struktur (nicht Inhalt) einer Tabelle anzeigen&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;struktur_nicht_inhalt_einer_tabelle_anzeigen&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:2,&amp;quot;secid&amp;quot;:3,&amp;quot;range&amp;quot;:&amp;quot;877-1604&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit4&quot; id=&quot;daten_einer_tabelle_ausgeben&quot;&gt;Daten einer Tabelle ausgeben&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;pre class=&quot;code python&quot;&gt;&lt;span class=&quot;kw1&quot;&gt;import&lt;/span&gt; sqlite3
&amp;nbsp;
&amp;nbsp;
sqliteConnection &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; sqlite3.&lt;span class=&quot;me1&quot;&gt;connect&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&#039;chinook.db&#039;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
cursor &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; sqliteConnection.&lt;span class=&quot;me1&quot;&gt;cursor&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&amp;quot;Database created and Successfully Connected to SQLite&amp;quot;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&amp;nbsp;
&lt;span class=&quot;co1&quot;&gt;# cursor.execute(&amp;quot;PRAGMA table_info(`albums`)&amp;quot;)&lt;/span&gt;
&lt;span class=&quot;co1&quot;&gt;# for column in cursor:&lt;/span&gt;
&lt;span class=&quot;co1&quot;&gt;#     print(column)&lt;/span&gt;
&lt;span class=&quot;co1&quot;&gt;# cursor.close()&lt;/span&gt;
&amp;nbsp;
&lt;span class=&quot;kw1&quot;&gt;with&lt;/span&gt; sqliteConnection:
	cur &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; sqliteConnection.&lt;span class=&quot;me1&quot;&gt;cursor&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
	cur.&lt;span class=&quot;me1&quot;&gt;execute&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&amp;quot;SELECT * FROM albums&amp;quot;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&amp;nbsp;
	rows &lt;span class=&quot;sy0&quot;&gt;=&lt;/span&gt; cur.&lt;span class=&quot;me1&quot;&gt;fetchall&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&amp;nbsp;
	&lt;span class=&quot;kw1&quot;&gt;for&lt;/span&gt; row &lt;span class=&quot;kw1&quot;&gt;in&lt;/span&gt; rows:
		&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;row&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&amp;nbsp;
sqliteConnection.&lt;span class=&quot;me1&quot;&gt;close&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;
&lt;span class=&quot;kw1&quot;&gt;print&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#40;&lt;/span&gt;&lt;span class=&quot;st0&quot;&gt;&amp;quot;The SQLite connection is closed&amp;quot;&lt;/span&gt;&lt;span class=&quot;br0&quot;&gt;&amp;#41;&lt;/span&gt;&lt;/pre&gt;

&lt;p&gt;
Ergebnis: 
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
Database created and Successfully Connected to SQLite
(1, &amp;#039;For Those About To Rock We Salute You&amp;#039;, 1)
(2, &amp;#039;Balls to the Wall&amp;#039;, 2).
.
.
(346, &amp;#039;Mozart: Chamber Music&amp;#039;, 274)
(347, &amp;#039;Koyaanisqatsi (Soundtrack from the Motion Picture)&amp;#039;, 275)
The SQLite connection is closed
[Finished in 0.1s]&lt;/pre&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Daten einer Tabelle ausgeben&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;daten_einer_tabelle_ausgeben&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:4,&amp;quot;secid&amp;quot;:4,&amp;quot;range&amp;quot;:&amp;quot;1605-&amp;quot;} --&gt;</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Thu, 06 Aug 2020 09:40:58 +0000</pubDate>
        </item>
        <item>
            <title>Variablen</title>
            <link>https://pflebit.de/doku.php?id=kb:software:python:variablen</link>
            <description>
&lt;h1 class=&quot;sectionedit1&quot; id=&quot;variablen&quot;&gt;Variablen&lt;/h1&gt;
&lt;div class=&quot;level1&quot;&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Variablen&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;variablen&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:1,&amp;quot;range&amp;quot;:&amp;quot;1-25&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit2&quot; id=&quot;variabletitle&quot;&gt;variable.title()&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Jedes Wort in der Variablen wird mit einem Großbuchstaben begonnen, auch wenn dieser klein geschrieben wurde.&lt;br/&gt;

Alle Buchstaben ab dem zweiten Buchstaben in allen Wörtern der Variable werden klein geschrieben.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;variable.title()&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;variabletitle&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:2,&amp;quot;range&amp;quot;:&amp;quot;26-267&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit3&quot; id=&quot;variableupper&quot;&gt;variable.upper()&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Jedes Wort in der Variablen wird ausschließlich in Großbuchstaben geschrieben.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;variable.upper()&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;variableupper&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:3,&amp;quot;range&amp;quot;:&amp;quot;268-377&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit4&quot; id=&quot;variablelower&quot;&gt;variable.lower()&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Jedes Wort in der Variablen wird ausschließlich in Kleinbuchstaben geschrieben.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;variable.lower()&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;variablelower&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:4,&amp;quot;range&amp;quot;:&amp;quot;378-487&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit5&quot; id=&quot;f-strings&quot;&gt;f-strings&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;
&lt;pre class=&quot;code&quot;&gt;gesamtname = f&amp;quot;{vorname} {nachname}&amp;quot;
begruessung = f&amp;quot;Hallo {vorname} {nachname}! Herzlichen willkommen in unserem Haus!&amp;quot;&lt;/pre&gt;

&lt;p&gt;
Das „f“ sorgt dafür, das alles was innerhalb der Anführungszeichen steht, miteinander verkettet wird.&lt;br/&gt;

Variablen müssen in geschweiften Klammern stehen.
&lt;/p&gt;

&lt;p&gt;
Die f-string-Methode werden erst ab Python 3.6 verwendet.&lt;br/&gt;

In vorherigen Python-Versionen wurde stattdessen die format-Methode verwendet:
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;gesamtname = &amp;quot;{} {}&amp;quot;.format(vorname, nachname)&lt;/pre&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;f-strings&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;f-strings&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:0,&amp;quot;secid&amp;quot;:5,&amp;quot;range&amp;quot;:&amp;quot;488-1007&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit6&quot; id=&quot;zeichentabulator_neue_zeile&quot;&gt;Zeichen: Tabulator, neue Zeile&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Innerhalb eines Textes können Sonderzeichen ausgegeben werden:
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;\n = Neue Zeile:\\ 
&amp;lt;code&amp;gt;
print(&amp;quot;Hallo \nWelt!&amp;quot;)&lt;/pre&gt;

&lt;p&gt;
Das \n fügt eine neue Zeile hinter dem Wort „Hallo“ ein.
&lt;/p&gt;

&lt;p&gt;
\t = Tabulatur:&lt;br/&gt;

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;print(&amp;quot;\tHallo Welt!&amp;quot;)&lt;/pre&gt;

&lt;p&gt;
Das \t setzt einen Tabulator vor das Wort „Hallo“.
&lt;/p&gt;

&lt;p&gt;
Kombination von neue Zeile und Tabulator:
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;print(&amp;quot;\nSag mal: \n\tHallo \n\tWelt!&amp;quot;)&lt;/pre&gt;

&lt;p&gt;
Man kann also auch beides miteinander kombinieren.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Zeichen: Tabulator, neue Zeile&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;zeichentabulator_neue_zeile&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:2,&amp;quot;secid&amp;quot;:6,&amp;quot;range&amp;quot;:&amp;quot;1008-1496&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit7&quot; id=&quot;variablerstrip_oder_lstrip_oder_strip&quot;&gt;variable.rstrip() oder lstrip() oder strip()&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Sofern in einer Textvariable am Ende (also auf der rechten Seite) \n (neue Zeile) eingebaut wurde, sorgt rstrip() dafür, dass diese entfernt werden. Es kommt also nicht mehr zu Zeilenumbrüchen.
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;hallo = &amp;#039;Wer bist du?\n\n&amp;#039;
print(hallo)
print(hallo)
print(hallo.rstrip())
print(hallo)
print(hallo)&lt;/pre&gt;

&lt;p&gt;
Im oben gezeigten Beispiel werden die Zeilenumbrüche zwar für den einen print-Befehl herausgenommen, jedoch sind diese bei einem erneuten Aufruf der Variable wieder vorhanden. Sie werden also in der Variablen nicht gelöscht.
&lt;/p&gt;

&lt;p&gt;
Sollen die Zeilenumbrüche in der Variablen gelöscht werden, so muss dieses bereits innerhalb der Variablen erfolgen:
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;hallo = &amp;#039;Wer bist du?\n\n&amp;#039;
hallo = hallo.rstrip()
print(hallo)&lt;/pre&gt;

&lt;p&gt;
Mit der Methode lstrip() können Leerzeichen von der linken Seite gelöscht werden.
&lt;/p&gt;

&lt;p&gt;
Mit der Methode strip() können Leerzeichen von beiden Seiten gelöscht werden.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;variable.rstrip() oder lstrip() oder strip()&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;variablerstrip_oder_lstrip_oder_strip&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:5,&amp;quot;secid&amp;quot;:7,&amp;quot;range&amp;quot;:&amp;quot;1497-2460&amp;quot;} --&gt;
&lt;h3 class=&quot;sectionedit8&quot; id=&quot;zen_of_python&quot;&gt;Zen of Python&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;p&gt;
Einige Regeln der Programmierung in Python werden dort „Zen of Python“ genannt und wurden von Tim Peters entwickelt.
&lt;/p&gt;

&lt;p&gt;
Um diese Regeln aufzurufen, geben Sie folgenden Code ein:
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;import this&lt;/pre&gt;

&lt;p&gt;
Nach dem Start des Programms erscheint der Zen-Text.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- EDIT{&amp;quot;target&amp;quot;:&amp;quot;section&amp;quot;,&amp;quot;name&amp;quot;:&amp;quot;Zen of Python&amp;quot;,&amp;quot;hid&amp;quot;:&amp;quot;zen_of_python&amp;quot;,&amp;quot;codeblockOffset&amp;quot;:7,&amp;quot;secid&amp;quot;:8,&amp;quot;range&amp;quot;:&amp;quot;2461-&amp;quot;} --&gt;</description>
            <author>anonymous@undisclosed.example.com (Anonymous)</author>
            <pubDate>Thu, 30 Jul 2020 12:57:20 +0000</pubDate>
        </item>
    </channel>
</rss>
