Perhaps the most definitive source for US securities exchanges, that appears to mostly match what you've provided as an example, is the output multicast output specification from the Consolidated Tape Association. This is the official report of all trades made.
https://www.ctaplan.com/tech-specs
Specially, this one:
https://www.nyse.com/publicdocs/ctaplan/notifications/trader-update/cts_output_spec.pdf
Deep in the documentation there's a field called the TRF Identifier (Trade Reporting Facility) that is a single character.
As at revision 81 of this document (dated June 2 2017), you'll see the following TRF Identifiers:
A NYSE MKT
B NASDAQ OMX BX
C NSX
D FINRA
I ISE
J Bats EDGA
K Bats EDGX
M CHX
N NYSE
P NYSE Arca
T NASDAQ OMX
V IEX
W CBSX
X NASDAQ OMX PSX
Y Bats BYX
Z Bats BZX
In the end, different data providers will have different identifiers for exchanges, and it's not clear which you actually want to use.
ISO 10383 describes a standard that has a Market Identifier Code (4 character) that is used in the FIX protocol and various other places too. See:
https://www.iso20022.org/10383/iso-10383-market-identifier-codes
Data feeds from vendors typically have their own conventions and quirks too. The merger-and-aquisition of exchanges has become commonplace so trying to identify an exchange is difficult.
eg. CME - did you mean CME, CBOT, NYMEX, COMEX, KCBOT or just CME? eg. InterContinental Exchange - did you mean IPE->ICE, NYBOT, WCE->ICE Futures Canada, or NYSE Euronext (which was NYSE, Archiplegao (Pacific Exchange), Euronext, AMEX -> NYSE Mkt -> Nyse Amercican)? There's probably a few more acquisitions along the way I've not mentioned too.