@lang:bytes.at
Access a single byte by index in a bytes value.
Returns: bytes
Syntax
Section titled “Syntax”@lang:bytes.at(value index)Arguments
Section titled “Arguments”| Name | Type | Description |
|---|---|---|
value | bytes | Source bytes value |
index | number | Zero-based byte index (negative counts from the end) |
See Also
Section titled “See Also”- @bytes.slice — extract a byte range
- @at — array element access
On-chain face (@bytes.at!)
Section titled “On-chain face (@bytes.at!)”Select one byte using a signed index; negative indexes count from the end. Out-of-bounds or fractional indexes are rejected. Runtime source and index remain live until execution.