What's wrong is you can't read.
> while((element=(getchar())!=EOF))
Is exactly the same as your original post, with more parentheses.
Go read my reply again, and study where I placed them.
No wait, that won't work this time, any more than it did last time.
Here, the critical ( ) emphasised while([B]([/B]element=getchar()[B])[/B]!=EOF)
Plus you ignored the whole clearerr thing I mentioned.
Here, paste this as your loop.
while(element=getchar()!=EOF)
{
[B] printf( "Interesting, element is decimal %d\n", element );
[/B] element=element-97;
[B] if ( element < 0 ) printf( "OMG, WTF, it's now %d\n", element );
[/B] l=(letters)element;
if(l>=a&&l<=z)
set[l]=true;
}
Putting temporary printf statements all over the place is the first step to debugging your own code.
When you get fed up of continually editing the code with new printf statements, and taking out ones you no longer need, then come back and we'll explain debuggers to you.