Why Gray code is an ordering of binary values arranged so that any two consecutive values differ in exactly one bit position. That property matters in shaft encoders, analog-to-digital converters and in mapping bits onto constellation points, because if the receiver or sensor picks the adjacent value by mistake, only one bit is wrong instead of several. In QAM and PSK constellation diagrams, Gray mapping means a symbol error between neighboring points causes just a single bit error, which greatly helps the error-correction decoder.
Watch out Binary Coded Decimal encodes each decimal digit as four bits, and EBCDIC and Extended ASCII are character sets for representing text; none of them controls how many bits change from one value to the next.
Gray = one bit changes at a time, so a neighbor slip costs only one bit error.