<?xml version="1.0" encoding="UTF-8" ?>
<!-- RSS generated by PHPBoost on Fri, 13 Mar 2026 05:14:11 +0100 -->

<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[Wiki MSX Village]]></title>
		<atom:link href="https://msxvillage.fr/syndication/rss/wiki/13" rel="self" type="application/rss+xml"/>
		<link>https://msxvillage.fr</link>
		<description><![CDATA[Derniers articles de la catégorie I]]></description>
		<copyright>(C) 2005-2026 PHPBoost</copyright>
		<language>fr</language>
		<generator>PHPBoost</generator>
		
		
		<item>
			<title><![CDATA[INSTR]]></title>
			<link>https://msxvillage.fr/wiki/instr</link>
			<guid>https://msxvillage.fr/wiki/instr</guid>
			<description><![CDATA[<fieldset class="formatter-container formatter-fieldset" style=""><legend><strong><span style="font-size: 20px;">INSTR</span></strong></legend><div class="formatter-content">Fonction qui permet de vérifier la présence d'une chaîne de caractères au sein d'une autre.<br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Syntaxe</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col"><a href="https://msxvillage.fr/wiki/instr">INSTR</a> ([indice de début de recherche], chaîne inspectée, chaîne recherchée)</td>
     </tr>
</table><br />
<br />
Les crochets indiquent un contenu optionnel.<br />
<br />
Si l'indice de début de recherche est omis, la recherche commencera à partir du premier caractère de la chaîne à traiter.<br />
<br />
La fonction renverra comme valeur la position de la chaîne recherchée dans la chaîne inspectée si elle est effectivement présente, 0 sinon.<br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Exemple</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">10 A$ = « MSX VILLAGE »<br />
                               20 <a href="https://msxvillage.fr/wiki/print">PRINT</a> <a href="https://msxvillage.fr/wiki/instr">INSTR</a> (A$, « VILLAGE »)<br />
                               30 <a href="https://msxvillage.fr/wiki/end">END</a></td>                            
             </tr>
</table><br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Résultat</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">Le programme va renvoyer la position de la chaîne « VILLAGE » dans la chaîne « MSX VILLAGE », soit la position 5 (l'espace est compté comme un caractère à part entière). </td>
    </tr>
</table><br />
<br />
</div></fieldset>]]></description>
			<pubDate>Tue, 27 Oct 2009 09:38:06 +0100</pubDate>
			
		</item>
		
		<item>
			<title><![CDATA[INT]]></title>
			<link>https://msxvillage.fr/wiki/int</link>
			<guid>https://msxvillage.fr/wiki/int</guid>
			<description><![CDATA[<fieldset class="formatter-container formatter-fieldset" style=""><legend><strong><span style="font-size: 20px;">INT</span></strong></legend><div class="formatter-content">Fonction qui renvoie la partie entière d'un nombre.<br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Syntaxe</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col"><a href="https://msxvillage.fr/wiki/int">INT</a> (nombre)</td>
     </tr>
</table><br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Exemple</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col"><a href="https://msxvillage.fr/wiki/print">PRINT</a> <a href="https://msxvillage.fr/wiki/int">INT</a> (3.14159)</td>                            
             </tr>
</table><br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Résultat</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">La ligne de programme va afficher la partie entière de PI, à savoir 3. </td>
    </tr>
</table><br />
<br />
</div></fieldset>]]></description>
			<pubDate>Tue, 27 Oct 2009 09:30:02 +0100</pubDate>
			
		</item>
		
		<item>
			<title><![CDATA[INP]]></title>
			<link>https://msxvillage.fr/wiki/inp</link>
			<guid>https://msxvillage.fr/wiki/inp</guid>
			<description><![CDATA[<fieldset class="formatter-container formatter-fieldset" style=""><legend><strong><span style="font-size: 20px;">INP</span></strong></legend><div class="formatter-content">Fonction qui permet de lire la valeur située dans un port du MSX.<br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Syntaxe</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col"><a href="https://msxvillage.fr/wiki/inp">INP</a> (numéro de port)</td>
     </tr>
</table><br />
<br />
Cette fonction nécessite de connaître les ports utilisés par le MSX. La valeur retournée est codée sous un octet, elle sera donc entre 0 et 255.<br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Exemple</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col"><a href="https://msxvillage.fr/wiki/print">PRINT</a> <a href="https://msxvillage.fr/wiki/inp">INP</a> (&H98)</td>                            
             </tr>
</table><br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Résultat</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">La ligne de programme va afficher le contenu du port &H98 (pour information, ce port est celui qui permet d'écrire dans la VRAM ou dans un registre du VDP). </td>
    </tr>
</table><br />
<br />
</div></fieldset>]]></description>
			<pubDate>Tue, 27 Oct 2009 09:27:20 +0100</pubDate>
			
		</item>
		
		<item>
			<title><![CDATA[INKEY$]]></title>
			<link>https://msxvillage.fr/wiki/inkey</link>
			<guid>https://msxvillage.fr/wiki/inkey</guid>
			<description><![CDATA[<fieldset class="formatter-container formatter-fieldset" style=""><legend><strong><span style="font-size: 20px;">INKEY$</span></strong></legend><div class="formatter-content">Fonction qui vérifie si une touche du clavier a été pressée.<br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Syntaxe</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">variable chaîne = <a href="https://msxvillage.fr/wiki/inkey">INKEY$</a></td>
     </tr>
</table><br />
<br />
Si une touche est pressée, la variable chaîne prend comme valeur le caractère entré, sinon, la chaîne vide («»).<br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Exemple</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">10 <a href="https://msxvillage.fr/wiki/print">PRINT</a> « Tapez C pour continuer »<br />
                               20 A$ = <a href="https://msxvillage.fr/wiki/inkey">INKEY$</a><br />
                               30 <a href="https://msxvillage.fr/wiki/if">IF</a> A$<> « C» <a href="https://msxvillage.fr/wiki/then">THEN</a> 20<br />
                               40 <a href="https://msxvillage.fr/wiki/print">PRINT</a> « Fin »<br />
                               50 <a href="https://msxvillage.fr/wiki/end">END</a></td>                            
             </tr>
</table><br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Résultat</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">Le programme va demander d'appuyer sur la touche C pour continuer. Il ne fera rien tant que la bonne touche ne sera pas pressée. </td>
    </tr>
</table><br />
<br />
</div></fieldset>]]></description>
			<pubDate>Tue, 27 Oct 2009 09:19:07 +0100</pubDate>
			
		</item>
		
		<item>
			<title><![CDATA[IF]]></title>
			<link>https://msxvillage.fr/wiki/if</link>
			<guid>https://msxvillage.fr/wiki/if</guid>
			<description><![CDATA[<fieldset class="formatter-container formatter-fieldset" style=""><legend><strong><span style="font-size: 20px;">IF...THEN...ELSE</span></strong></legend><div class="formatter-content">Instructions servant à effectuer des tests sur des variables.<br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Syntaxe</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col"><a href="https://msxvillage.fr/wiki/if">IF</a> [opérateur booléen](variable ou expression booléenne) [opérateur booléen (variable ou expression booléenne)] <a href="https://msxvillage.fr/wiki/then">THEN</a> instructions [<a href="https://msxvillage.fr/wiki/else">ELSE</a> instructions]</td>
    </tr>
</table><br />
<br />
Les crochets indiquent un contenu optionnel.<br />
<br />
Les opérateurs booléens sont <a href="https://msxvillage.fr/wiki/and">AND</a>, <a href="https://msxvillage.fr/wiki/or">OR</a>, <a href="https://msxvillage.fr/wiki/xor">XOR</a>, <a href="https://msxvillage.fr/wiki/not">NOT</a>, <a href="https://msxvillage.fr/wiki/eqv">EQV</a> ou <a href="https://msxvillage.fr/wiki/imp">IMP</a><br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Exemple</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">10 <a href="https://msxvillage.fr/wiki/input">INPUT</a> "Quel est ton age";A<br />
                        20 <a href="https://msxvillage.fr/wiki/if">IF</a> A>=18 <a href="https://msxvillage.fr/wiki/then">THEN</a> 30 <a href="https://msxvillage.fr/wiki/else">ELSE</a> 40<br />
                        30 <a href="https://msxvillage.fr/wiki/print">PRINT</a> "Tu es majeur" : <a href="https://msxvillage.fr/wiki/end">END</a><br />
                        40 <a href="https://msxvillage.fr/wiki/print">PRINT</a> "Tu es mineur" : <a href="https://msxvillage.fr/wiki/end">END</a></td>
             </tr>
</table><br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Résultat</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">Le programme teste l'âge entré par l'utilisateur en ligne 10. Si cet âge est supérieur ou égal à 18, le programme continue en ligne 30, sinon, en ligne 40.</td>
    </tr>
</table><br />
<br />
<h3 class="formatter-title">Remarques :</h3><br />
Les instructions après <a href="https://msxvillage.fr/wiki/then">THEN</a> et <a href="https://msxvillage.fr/wiki/else">ELSE</a> peuvent être remplacées par des numéros de lignes.<br />
<br />
Les expressions booléennes concernent en général des tests sur les égalités ou inégalités. Le MSX renvoie -1 si une expression est "vraie", 0 si elle est "fausse". C'est aussi pour cela qu'on peut utiliser des variables au lieu d'expressions booléennes . Si on a une variable A, on peut écrire :<br />
<br />
<a href="https://msxvillage.fr/wiki/if">IF</a> A <a href="https://msxvillage.fr/wiki/then">THEN</a> ... <a href="https://msxvillage.fr/wiki/else">ELSE</a>...<br />
<br />
Si A = -1, les instructions qui suivent le <a href="https://msxvillage.fr/wiki/then">THEN</a> sont exécutées, sinon ce sont celles qui suivent le <a href="https://msxvillage.fr/wiki/else">ELSE</a>.<br />
<br />
Les différentes instructions consécutives qui suivent un <a href="https://msxvillage.fr/wiki/then">THEN</a> ou un <a href="https://msxvillage.fr/wiki/else">ELSE</a> doivent être séparées par ":". Il faut savoir qu'une suite d'instructions ne peut pas excéder une ligne de MSX-Basic (256 caractères).<br />
Ces instructions peuvent elles aussi être de type <a href="https://msxvillage.fr/wiki/if">IF</a>... <a href="https://msxvillage.fr/wiki/then">THEN</a> ... <a href="https://msxvillage.fr/wiki/else">ELSE</a>...<br />
</div></fieldset>]]></description>
			<pubDate>Tue, 20 Oct 2009 13:54:54 +0200</pubDate>
			
		</item>
		
		<item>
			<title><![CDATA[I]]></title>
			<link>https://msxvillage.fr/wiki/i</link>
			<guid>https://msxvillage.fr/wiki/i</guid>
			<description><![CDATA[Liste des instructions commençant par I :]]></description>
			<pubDate>Tue, 20 Oct 2009 10:55:50 +0200</pubDate>
			
		</item>
		
		<item>
			<title><![CDATA[IMP]]></title>
			<link>https://msxvillage.fr/wiki/imp</link>
			<guid>https://msxvillage.fr/wiki/imp</guid>
			<description><![CDATA[<fieldset class="formatter-container formatter-fieldset" style=""><legend><strong><span style="font-size: 20px;">IMP</span></strong></legend><div class="formatter-content">Opérateur logique permettant soit de tester si une condition en implique une autre, soit d'appliquer des modifications sur la représentation binaire de deux nombres.<br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Syntaxe</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">Les opérateurs logiques peuvent agir aussi bien sur des conditions que sur des nombres. Pour des conditions, le résultat en MSX-Basic est -1 pour vrai, 0 pour faux. Pour les nombres, le résultat dépend de la représentation binaire de ceux-ci. Les différents résultats peuvent être placés dans des variables.<br />
<br />
                 La syntaxe est la suivante :<br />
<br />
                operateur1 <a href="https://msxvillage.fr/wiki/imp">IMP</a> operateur2<br />
</td>
    </tr>
</table><br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Exemple de la vie courante</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">On utilisera l'exemple du leitmotiv de Spiderman : "Un grand pouvoir implique de grandes responsabilités". Partant de là, on peut penser que pas de pouvoir n'implique pas de responsabilité. Par contre, avoir de grandes responsabilités ne nécessite pas forcément de grand pouvoir... C'est là toute la subtilité de l'implication. </td>
     </tr>
</table><br />
<br />
<br />
Voici le tableau de vérité de l'opérateur (C1 : condition 1, C2 : condition 2,  0 : faux, 1 : vrai)<br />
<br />
<br />
<table class="formatter-table">
           <tr class="formatter-table-row">
        <td class="formatter-table-col"><p style="text-align: center;">C1</p></td>
                    <td class="formatter-table-col"><p style="text-align: center;">C2</p></td>
                <td class="formatter-table-col"><p style="text-align: center;">C1 IMP C2</p></td>
    </tr>
         <tr class="formatter-table-row">
        <td class="formatter-table-col"><p style="text-align: center;">0</p></td>
        <td class="formatter-table-col"><p style="text-align: center;">0</p></td>
                        <td class="formatter-table-col"><p style="text-align: center;">1</p></td>
    </tr>
            <tr class="formatter-table-row">
        <td class="formatter-table-col"><p style="text-align: center;">0</p></td>
        <td class="formatter-table-col"><p style="text-align: center;">1</p></td>
                        <td class="formatter-table-col"><p style="text-align: center;">1</p></td>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col"><p style="text-align: center;">1</p></td>
        <td class="formatter-table-col"><p style="text-align: center;">0</p></td>
                        <td class="formatter-table-col"><p style="text-align: center;">0</p></td>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col"><p style="text-align: center;">1</p></td>
        <td class="formatter-table-col"><p style="text-align: center;">1</p></td>
                        <td class="formatter-table-col"><p style="text-align: center;">1</p></td>
    </tr>
 </table><br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Exemple</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">10 <a href="https://msxvillage.fr/wiki/input">INPUT</a> "As-tu de grands pouvoirs (O/N)" ;A$<br />
                        20 <a href="https://msxvillage.fr/wiki/input">INPUT</a>"As-tu de grandes responsabilités (O/N)" ;B$<br />
                        30 <a href="https://msxvillage.fr/wiki/if">IF</a> A$="O" <a href="https://msxvillage.fr/wiki/imp">IMP</a> B$="O" <a href="https://msxvillage.fr/wiki/then">THEN</a> <a href="https://msxvillage.fr/wiki/print">PRINT</a> "C'est très bien" <a href="https://msxvillage.fr/wiki/else">ELSE</a> <a href="https://msxvillage.fr/wiki/print">PRINT</a> "C'est dommage, tu gâches tes capacités... "<br />
                        40 <a href="https://msxvillage.fr/wiki/end">END</a></td>
     </tr>
</table><br />
<br />
<table class="formatter-table">
    <tr class="formatter-table-row">
        <th class="formatter-table-head">Résultat</th>
    </tr>
    <tr class="formatter-table-row">
        <td class="formatter-table-col">Le seul cas qui nous amène à un résultat négatif de l'évaluation, c'est si l'implication n'est pas vérifiée, soit quand la personne a de grands pouvoirs, mais pas de responsabilités.<br />
</td>
    </tr>
</table><br />
<br />
</div></fieldset>]]></description>
			<pubDate>Wed, 14 Oct 2009 10:20:33 +0200</pubDate>
			
		</item>
		
	</channel>
</rss>
