#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
int charcnt(const char *ptr, unsigned char ch);
int main(void)
{
    char *ptr = "help yourself";
    unsigned char ch;
    int flag = 0;
    while(toupper(ch = getchar()) != 'Q')
    {
        if(ch == '\n')
              continue;
        flag = charcnt(ptr, ch);
        if(0 == flag)
             puts("no founded");
        else 
        {
             printf("have appeared for %d time%s\n", flag, 1 == flag ? "" : "s");
        }
        printf("not founded\n");
    }
    putchar('\n');
    system("pause");
    return 0;
}
int charcnt(const char *ptr, unsigned char ch)
{
    int count = 0;
    while(*ptr)
    {
               if(ch == *ptr)
               {
                     count++;
               }
               ptr++;
    }
    return count;
}