От: | rg45 | ||
Дата: | 23.12.19 13:45 | ||
Оценка: | 4 (1) |
__>std::set<int> associative_container{ 1, 2, 3, 4 };
__>int back_value{ *std::prev(std::end(associative_container)) };
__>
Notes
The begin iterator is not decrementable and the behavior is undefined if --container.begin() is evaluated. A bidirectional iterator does not have to be dereferenceable to be decrementable (in particular, the end iterator is not dereferenceable but is decrementable)