You should use single quotes for chars and do double equals for equality (otherwise it changes the value of c)
if( c >= 'A' && c <= 'Z' || c == ' ' || c == ',') {
Furthermore, you might consider something like this to make your boolean logic more clear:
if( (c >= 'A' && c <= 'Z') || c == ' ' || c == ',') {
Although your boolean logic structure works equivalently (&& takes precedence over ||), things like this might trip you up in the future.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…