Skip to content

Slices practice problems in Rust

Difficulty:
Category & tags Filters active
Category:
Tag:

Showing 16 of 16

Title Difficulty
Accept string-like values with AsRef Medium
Bounds checks: five safe ways to express access Hard
Build a safe mutable-slice split Medium
Carry a running maximum through mutable iteration Medium
E0499: cannot borrow as mutable more than once Medium
Extension traits: adding methods to types you do not own Medium
Find the largest window sum with slices Medium
&mut: exclusive access, and why mut appears twice Easy
Non-lexical lifetimes: a borrow ends at its last use Easy
Remove duplicates while preserving order Easy
Slice and array patterns, and rest @ .. Medium
Slices are borrows Easy
split_at_mut and the disjointness-proof APIs Medium
Store and transpose a grid in one flat buffer Medium
Subtract the minimum with a mutable iterator Medium
windows and chunks are slice methods, not iterator adapters Medium