On this page
zlib.adler32
Up: zlib | Next: zlib.compress
Rel: zlib.compress, zlib.compressobj, zlib.crc32, zlib.decompress
Ref: docs.python.org — zlib.adler32
Tags: #public #python3 #stdlib #zlib
Import
import zlib
from zlib import adler32
Signature & Overview
zlib.adler32(data, value=1, /)
Compute an Adler-32 checksum of data.
Usage
import zlib
c = zlib.adler32(b'hello')
c = zlib.adler32(b' world', c)
assert c == zlib.adler32(b'hello world')
Gotchas
- Faster than
crc32, weaker error detection on short inputs: Always unsigned 32-bitint.
REPL Inspect
from zlib import adler32
help(adler32)
Linked from
Related notes
- tuts/python3/stdlib_module/zlib/compress Linked here; links to this page; shared tags: #stdlib, #zlib
- tuts/python3/stdlib_module/zlib/compressobj Linked here; links to this page; shared tags: #stdlib, #zlib
- tuts/python3/stdlib_module/zlib/crc32 Linked here; links to this page; shared tags: #stdlib, #zlib
- tuts/python3/stdlib_module/zlib/decompress Linked here; links to this page; shared tags: #stdlib, #zlib
- tuts/python3/stdlib_module/zlib Linked here; links to this page; shared tags: #stdlib
- tuts/python3/stdlib_module/zlib/decompressobj links to this page; shared tags: #stdlib, #zlib
- tuts/python3/stdlib_module/zlib/error links to this page; shared tags: #stdlib, #zlib
- tuts/c/stdlib shared tags: #stdlib
- tuts/c/stdlib/assert shared tags: #stdlib
- tuts/c/stdlib/assert/assert shared tags: #stdlib