You can recognize JWTs without decoding by checking the string format:
JSON Web Tokens follow this format → ALGO+TokenType.Payload.Signature
So obviously the only valid JWT in your question is “B”.
B) eyJhbGciOiJIUzM4NCIsInR5cCI6IkpXVCJ9
.
eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6
IkhpIEhhY2tlciBOZXdzIiwiaWF0IjoxNTE2
MjM5MDIyfQ
.
IlIR9_imqGCgEVG_QUb4LhDwSeNhYc50t3Ij
5x126scVNJFQqCveblmHx__tqjaI
But this does not matter because you are not supposed to decode random strings expecting them to be JSON Web Tokens. That would be as stupid as assuming that any 32-bytes string is MD5 or any 40-bytes string is SHA1, etc. You either know what your input’s format is or you do not in which case you should not even attempt to decode it because it clearly is not a valid input.