Skip to main content
. 2020 Feb 11;22(2):203. doi: 10.3390/e22020203
Algorithm 8 Manticore example C program.
  • 1:

    #include <stdio.h>

  • 2:

    #include <stdlib.h>

  • 3:

    #include <unistd.h>

  • 4:

     

  • 5:

    int main(int argc, char **argv) {

  • 6:

     

  • 7:

        unsigned int cmd;

  • 8:

     

  • 9:

        if(read(0, &cmd, sizeof(cmd)) != sizeof(cmd))

  • 10:

       {

  • 11:

               printf("Error reading stdin");

  • 12:

               exit=1;

  • 13:

       }

  • 14:

     

  • 15:

       if(cmd > 0x41)

  • 16:

       {

  • 17:

               printf("Message: it is greater than 0x41");

  • 18:

       } else {

  • 19:

               printf("Message: it is less than or equal to 0x41");

  • 20:

       }

  • 21:

     

  • 22:

       return 0;

  • 23:

    }