sorting.cpp: In function 'int findSwapPairs(int, int*, int, int*, int*, int*, int*)':
sorting.cpp:18:5: warning: this 'for' clause does not guard... [-Wmisleading-indentation]
18 | for(int i=0;i<N;i++)
| ^~~
sorting.cpp:21:3: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'for'
21 | vector<pair<ll,ll>>v;
| ^~~~~~
sorting.cpp:24:22: error: expected ')' before ';' token
24 | v.pb({pos[i],i};
| ~ ^
| )
sorting.cpp:31:15: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<std::pair<long long int, long long int> >::size_type' {aka 'long unsigned int'} [-Wsign-compare]
31 | for(int i=0;i<v.size();i++)
| ~^~~~~~~~~
sorting.cpp:5:11: warning: conversion from 'long long int' to 'int' may change value [-Wconversion]
5 | #define F first
sorting.cpp:33:26: note: in expansion of macro 'F'
33 | P[i]=v[i].F;
| ^
sorting.cpp:6:11: warning: conversion from 'long long int' to 'int' may change value [-Wconversion]
6 | #define S second
sorting.cpp:34:26: note: in expansion of macro 'S'
34 | Q[i]=v[i].S;
| ^
sorting.cpp:36:20: warning: conversion from 'std::vector<std::pair<long long int, long long int> >::size_type' {aka 'long unsigned int'} to 'int' may change value [-Wconversion]
36 | return v.size();
| ~~~~~~^~
sorting.cpp:14:39: warning: unused parameter 'M' [-Wunused-parameter]
14 | int findSwapPairs(int N, int S[], int M, int X[], int Y[], int P[], int Q[])
| ~~~~^
sorting.cpp:14:46: warning: unused parameter 'X' [-Wunused-parameter]
14 | int findSwapPairs(int N, int S[], int M, int X[], int Y[], int P[], int Q[])
| ~~~~^~~
sorting.cpp:14:55: warning: unused parameter 'Y' [-Wunused-parameter]
14 | int findSwapPairs(int N, int S[], int M, int X[], int Y[], int P[], int Q[])
| ~~~~^~~