counting chars
switches in c