training

Code I wrote during training
git clone git://git.bitsmanent.org/training
Log | Files | Refs | README

getintbychar.c (456B)


      1 /* Esercizio 2.29 (Cap. 2)
      2    Determina l'intero equivalente almeno di:
      3    A B C a b c 0 1 2 $ * + / e dello spazio. */
      4 
      5 #include <stdio.h>
      6 
      7 int main()
      8 {
      9    printf("A = %d\tB = %d\tC = %d\n", 'A', 'B', 'C');
     10    printf("a = %d\tb = %d\tc = %d\n", 'a', 'b', 'c');
     11    printf("0 = %d\t1 = %d\t2 = %d\n", '0', '1', '2');
     12    printf("$ = %d\t* = %d\t+ = %d\n", '$', '*', '+');
     13    printf("/ = %d\t@ = %d\t^ = %d\n", '/', '@', '^');
     14 
     15    return 0;
     16 } /* E0F main */
     17