How to get the serial monitor to only show a specific part of what it outputs?

I recommend C code.

That is all I can do with the very poor information you have provided so far.