How can I get the count of the @ character from the following output. I had used tr command and extracted? I am curious to know what is the best way to do it? I mean other ways of doing the same thing.
{running_device,[test@01,test@02]},
My solution was:
echo '{running_device,[test@01,test@02]},' | tr ',' '\n' | grep '@' | wc -l