12 lines
181 B
Plaintext
12 lines
181 B
Plaintext
|
# -*- mode: snippet -*-
|
||
|
# name: partition
|
||
|
# key: ptn
|
||
|
# --
|
||
|
auto pos = std::partition(std::begin(${1:container}), std::end($1), []($2) {
|
||
|
$3
|
||
|
});
|
||
|
if (pos != std::end($1)) {
|
||
|
$4
|
||
|
}
|
||
|
$0
|