Logo

Programming-Idioms

History of Idiom 224 > diff from v18 to v19

Edit summary for version 19 by Plecra:
New Rust implementation by user [Plecra]

Version 18

2020-06-25, 11:25:07

Version 19

2020-07-15, 15:32:43

Idiom #224 Add element to the beginning of the list

Insert element x at the beginning of list items.

Idiom #224 Add element to the beginning of the list

Insert element x at the beginning of list items.

Extra Keywords
prepend prefix start
Extra Keywords
prepend prefix start
Imports
use std::collections::VecDeque
Code
items.push_front(x);
Doc URL
https://doc.rust-lang.org/std/collections/struct.VecDeque.html#method.push_front