[range.join.with.overview]

# 25 Ranges library [[ranges]](./#ranges)

## 25.7 Range adaptors [[range.adaptors]](range.adaptors#range.join.with.overview)

### 25.7.15 Join with view [[range.join.with]](range.join.with#overview)

#### 25.7.15.1 Overview [range.join.with.overview]

[1](#1)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/ranges.tex#L7186)

join_with_view takes a view and a delimiter, and
flattens the view,
inserting every element of the delimiter
in between elements of the view[.](#1.sentence-1)

The delimiter can be a single element or a view of elements[.](#1.sentence-2)

[2](#2)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/ranges.tex#L7193)

The name views​::​join_with denotes
a range adaptor object ([[range.adaptor.object]](range.adaptor.object "25.7.2 Range adaptor objects"))[.](#2.sentence-1)

Given subexpressions E and F,
the expression views​::​join_with(E, F) is expression-equivalent tojoin_with_view(E, F)[.](#2.sentence-2)

[3](#3)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/ranges.tex#L7201)

[*Example [1](#example-1)*: vector<string> vs = {"the", "quick", "brown", "fox"};for (char c : vs | views::join_with('-')) { cout << c;}// The above prints the-quick-brown-fox â *end example*]
