Run ❯
Get your
own
website
×
Change Orientation
Change Theme, Dark/Light
Go to Spaces
#include
#include
#include
using namespace std; int main() { vector
numbers = {1, 7, 3, 5, 9, 2}; vector
other = {9, 7, 5, 3, 2, 1}; if (is_permutation(numbers.begin(), numbers.end(), other.begin())) { cout << "Permutation found"; } else { cout << "No permutation found"; } return 0; }
Permutation found