mardi 27 septembre 2016
    1. Program Touche;
    2. Var c : Char;
    3. nature : String;
    4. Begin
    5. Writeln('Taper sur une touche');
    6. Readln(c);
    7. Case c of
    8. 'a'..'z','A'..'Z' : IF UPCASE(c) in ['A','E','I','U','O','Y']
    9. Then nature := 'Voyelle'
    10. Else nature := 'Consonne';
    11. '0'..'9' : nature := 'Chiffre';
    12. Else nature := 'Symbole';
    13. End;
    14. Writeln(nature);
    15. End.

0 commentaires:

Enregistrer un commentaire

Page Facebook

Turbo Pascal 32 bits

Turbo Pascal 64 bits