해밍 거리

길이가 같은 두 시퀀스에서 다른 위치를 비트 또는 바이트 단위로 셉니다.

입력: 텍스트결과: 텍스트

텍스트 입력

도구 옵션

예제

Count three substitutions in the classic string example

Byte distance counts changed positions, not insertions or deletions.

입력

karolin

kathrin

Expected answer

3
구분자
단위
Byte
입력 유형
Raw string
Find a one-bit change in a two-byte packet

FF versus FE changes one bit in the second byte.

입력

00ff|00fe

Expected answer

1
구분자
|
단위
Bit
입력 유형
Hex
Compare every bit in opposite byte values

Two opposite bytes differ in all 16 bit positions.

입력

0000|ffff

Expected answer

16
구분자
|
단위
Bit
입력 유형
Hex
Count changed bytes in two IPv4-style headers

Only the final byte differs; this is a short synthetic header fragment.

입력

45000014|45000028

Expected answer

1
구분자
|
단위
Byte
입력 유형
Hex
Separate byte changes from bit changes in ASCII

ASCII A and a differ by the single 0x20 bit.

입력

A|a

Expected answer

1
구분자
|
단위
Bit
입력 유형
Raw string

매개변수

매개변수기본값입력 및 선택 항목
구분자"\\n\\n"\n, \r, \t 등의 이스케이프 시퀀스 지원
단위바이트바이트, 비트
입력 유형원시 문자열원시 문자열, 헥스

관련 도구

유틸리티

작업 참고 자료

원본 기술 문서 보기 (English)