View Code of Problem 84

#include <stdio.h>
#include <string.h>
int main()
{
    char a[100];
    while(gets(a))
    {   int i=0;
        for(i=0;i+3<strlen(a);i++)
            if ((a[i]=='S'||a[i]=='s')
                &&(a[i+1]=='A'||a[i+1]=='a')
                &&(a[i+2]=='L'||a[i+2]=='l')
                &&(a[i+3]=='T'||a[i+3]=='t'))
                puts(a);
    }
}

Double click to view unformatted code.


Back to problem 84