Remove extra characters and sum the columns

I have data extracted like this:

A=%123% B=%456% C=%789%
A=%111% B=%222% C=%333%
A=%777% B=%888% C=%999%

Can someone please help me with a script to remove all the % signs and get the totals for A, B and C.
So output will be:

A=1368
B=666
C=2664

Thank you!

Something like this,

awk -F"[=%]" '{a+=$3;b+=$6;c+=$9} END{printf "A="a"\nB="b"\nC="c"\n"}' infile

Cool! Just what I'm looking for. Thank you for the quick response. :slight_smile: