[#absl-Cord-operator_subs] = xref:absl.adoc[absl]::xref:absl/Cord.adoc[Cord]::operator[] :relfileprefix: ../../ :mrdocs: Gets the "i"th character of the Cord and returns it, provided that 0 <= i < Cord.size(). == Synopsis Declared in `<absl/strings/cord.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- char operator[](size_t i) const; ---- == Description NOTE: This routine is reasonably efficient. It is roughly logarithmic based on the number of chunks that make up the cord. Still, if you need to iterate over the contents of a cord, you should use a CharIterator/ChunkIterator rather than call operator[] repeatedly in a loop. == Return Value The character at index `i`. == Parameters [cols="1,4"] |=== | Name| Description | *i* | The index of the character to retrieve. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#