func_code_string: #include <bits/stdc++.h>   using namespace std;   int main() {     int n = 3, i, j, a, b;     vector<pair<int, int> > v, v2;     for (i = 0; i < 3; i++) {       scanf( %d%d , &a, &b);       v.push_back(make_pair(a, b));       v2.push_back(make_pair(b, a));     }     int cnt, c2, c3;     sort(v.begin(), v.end());     sort(v2.begin(), v2.end());     if (v[0].first == v[1].first) {       if (v[1].first == v[2].first)         cnt = 1;       else if (v[1].second == v[2].second)         cnt = 2;       else         cnt = 3;     } else {       if (v[1].first == v[2].first)         cnt = 2;       else if (v[1].second == v[2].second)         cnt = 3;       else         cnt = 3;     }     if (v[0].first == v[2].first) {       if (v[1].first == v[2].first)         c2 = 1;       else if (v[1].second == v[2].second)         c2 = 2;       else         c2 = 3;     } else {       if (v[1].first == v[2].first)         c2 = 2;       else if (v[1].second == v[2].second)         c2 = 3;       else         c2 = 3;     }     if (v[0].first == v[2].first) {       if (v[1].first == v[0].first)         c3 = 1;       else if (v[1].second == v[0].second)         c3 = 2;       else         c3 = 3;     } else {       if (v[1].first == v[0].first)         c3 = 2;       else if (v[1].second == v[0].second)         c3 = 3;       else         c3 = 3;     }     cnt = min(cnt, min(c2, c3));     int c1;     if (v2[0].first == v2[1].first) {       if (v2[1].first == v2[2].first)         c1 = 1;       else if (v2[1].second == v2[2].second)         c1 = 2;       else         c1 = 3;     } else {       if (v2[1].first == v2[2].first)         c1 = 2;       else if (v2[1].second == v2[2].second)         c1 = 3;       else         c1 = 3;     }     if (v2[0].first == v2[2].first) {       if (v2[1].first == v2[2].first)         c2 = 1;       else if (v2[1].second == v2[2].second)         c2 = 2;       else         c2 = 3;     } else {       if (v2[1].first == v2[2].first)         c2 = 2;       else if (v2[1].second == v2[2].second)         c2 = 3;       else         c2 = 3;     }     if (v2[0].first == v2[2].first) {       if (v2[1].first == v2[0].first)         c3 = 1;       else if (v2[1].second == v2[0].second)         c3 = 2;       else         c3 = 3;     } else {       if (v2[1].first == v2[0].first)         c3 = 2;       else if (v2[1].second == v2[0].second)         c3 = 3;       else         c3 = 3;     }     if (v[0].first == v[1].first) {       if (v[2].second < v[1].second && v[2].second > v[0].second) {         cout <<  3  << endl;         exit(0);       } else if (v[2].second < v[0].second && v[2].second > v[1].second) {         cout <<  3  << endl;         exit(0);       } else {         cnt = min(cnt, min(c1, min(c2, c3)));       }     } else if (v2[0].first == v2[1].first) {       if (v2[2].second < v2[1].second && v2[2].second > v2[0].second) {         cout <<  3  << endl;         exit(0);       } else if (v2[2].second < v2[0].second && v2[2].second > v2[1].second) {         cout <<  3  << endl;         exit(0);       } else {         cnt = min(cnt, min(c1, min(c2, c3)));       }     } else       cnt = min(cnt, min(c1, min(c2, c3)));     reverse(v.begin(), v.end());     reverse(v2.begin(), v2.end());     int cnt1;     if (v[0].first == v[1].first) {       if (v[1].first == v[2].first)         cnt1 = 1;       else if (v[1].second == v[2].second)         cnt1 = 2;       else         cnt1 = 3;     } else {       if (v[1].first == v[2].first)         cnt1 = 2;       else if (v[1].second == v[2].second)         cnt1 = 3;       else         cnt1 = 3;     }     if (v[0].first == v[2].first) {       if (v[1].first == v[2].first)         c2 = 1;       else if (v[1].second == v[2].second)         c2 = 2;       else         c2 = 3;     } else {       if (v[1].first == v[2].first)         c2 = 2;       else if (v[1].second == v[2].second)         c2 = 3;       else         c2 = 3;     }     if (v[0].first == v[2].first) {       if (v[1].first == v[0].first)         c3 = 1;       else if (v[1].second == v[0].second)         c3 = 2;       else         c3 = 3;     } else {       if (v[1].first == v[0].first)         c3 = 2;       else if (v[1].second == v[0].second)         c3 = 3;       else         c3 = 3;     }     cnt1 = min(cnt1, min(c2, c3));     if (v2[0].first == v2[1].first) {       if (v2[1].first == v2[2].first)         c1 = 1;       else if (v2[1].second == v2[2].second)         c1 = 2;       else         c1 = 3;     } else {       if (v2[1].first == v2[2].first)         c1 = 2;       else if (v2[1].second == v2[2].second)         c1 = 3;       else         c1 = 3;     }     if (v2[0].first == v2[2].first) {       if (v2[1].first == v2[2].first)         c2 = 1;       else if (v2[1].second == v2[2].second)         c2 = 2;       else         c2 = 3;     } else {       if (v2[1].first == v2[2].first)         c2 = 2;       else if (v2[1].second == v2[2].second)         c2 = 3;       else         c2 = 3;     }     if (v2[0].first == v2[2].first) {       if (v2[1].first == v2[0].first)         c3 = 1;       else if (v2[1].second == v2[0].second)         c3 = 2;       else         c3 = 3;     } else {       if (v2[1].first == v2[0].first)         c3 = 2;       else if (v2[1].second == v2[0].second)         c3 = 3;       else         c3 = 3;     }     if (v[0].first == v[1].first) {       if (v[2].second < v[1].second && v[2].second > v[0].second) {         cout <<  3  << endl;         exit(0);       } else if (v[2].second < v[0].second && v[2].second > v[1].second) {         cout <<  3  << endl;         exit(0);       } else {         cnt1 = min(cnt1, min(c1, min(c2, c3)));       }     } else if (v2[0].first == v2[1].first) {       if (v2[2].second < v2[1].second && v2[2].second > v2[0].second) {         cout <<  3  << endl;         exit(0);       } else if (v2[2].second < v2[0].second && v2[2].second > v2[1].second) {         cout <<  3  << endl;         exit(0);       } else {         cnt1 = min(cnt1, min(c1, min(c2, c3)));       }     } else       cnt1 = min(cnt1, min(c1, min(c2, c3)));     cnt = min(cnt, cnt1);     cout << cnt << endl;     return 0;   }   