How to manipulate the output ???

In an operation, I have output like 22562K [(some no)K] I want to manipulate this and want to perform some mathematical operations on that, any idea how can I get the digit no?

pls do check other posting before posting new one..

here is the previous post to remove the last character :

val=22562K
echo $val | tr -cd [0-9]