method String.push
Appends the text s.
Example:
fn main() io {
var s = String.new()
s.push("a")
s.push("bc")
print(s.freeze())
}Output
abc
Appends a string.
Example:
fn main() io {
var s = String.new()
s.push("a")
s.push("bc")
print(s.freeze())
}Output
abc
pub(api) var fn push(s: str)Complexity. O(len(s)) amortized.
Since. 1.0.0-beta
Parameters
| Name | Type |
|---|---|
s | str |
Effects
none declared (pure unless the body says otherwise)
Defined in: std/core/collections.oxl:1235