#include #include using namespace std; vector quickSort(vector vec); int main() { int n; cin >> n; vector vec(n); for(int i=0;i> vec[i]; } vec = quickSort(vec); if(n%2 == 0){ cout << double(vec[n/2-1] + vec[n/2])/2 << endl; }else{ cout << vec[n/2] << endl; } } vector quickSort(vector vec){ if (vec.size() <= 1){ return vec; } int p = vec[0]; vector left; vector right; for(int i=1;i