#include<bits/stdc++.h>
#define rep(i, n) for(int i=0;i<(n);++i)
#define per(i, n) for(int i=(n)-1;i>=0;--i)
#define repa(i, n) for(int i=1;i<(n);++i)
#define foreach(i, n) for(auto &i:(n))
#define pii pair<int, int>
#define pll pair<long long, long long>
#define all(x) (x).begin(), (x).end()
#define bit(x) (1ll << (x))
using ll = long long;
//const ll MOD = (ll)1e9+7;
const ll MOD = 998244353;
const int INF = (ll)1e9+7;
const ll INFLL = (ll)1e18;
using namespace std;
template<class t>
using vvector = vector<vector<t>>;
template<class t>
using vvvector = vector<vector<vector<t>>>;
template<class t>
using priority_queuer = priority_queue<t, vector<t>, greater<t>>;
template<class t, class u> bool chmax(t &a, u b){if(a<b){a=b;return true;}return false;}
template<class t, class u> bool chmin(t &a, u b){if(a>b){a=b;return true;}return false;}
#ifdef DEBUG
#define OUTPUT(x) (output(x), output("\n"))
#else
#define OUTPUT(x) (void)0
#endif

ll modpow(ll x, ll b){
    ll res = 1;
    while(b){
        if(b&1)res = res * x % MOD;
        x = x * x % MOD;
        b>>=1;
    }
    return res;
}

ll modinv(ll x){
    return modpow(x, MOD-2);
}

bool was_output = false;
template<class t>
void output(t a){
    if(was_output)cout << " ";
    cout << a;
    was_output = true;
}
void outendl(){
    was_output = false;
    cout << endl;
}
ll in(){
    ll res;
    scanf("%lld", &res);
    return res;
}

pll start, goal;
int n;
vector<pll> supring;
const long double PI = 3.14159265358979323846264558L;
long double quot_cir = 5 * PI;
long double half_cir = 10 * PI;
long double true_cir = 20 * PI;

pll inpll(){
    ll a = in();
    ll b = in();
    return pll(a, b);
}

void input(){
    start = inpll();
    goal = inpll();
    n = in();
    supring.resize(n);
    foreach(i, supring){
        i = inpll();
    }
}

long double solve(){
    long double res = 0;
    if(abs(start.first-goal.first)<abs(start.second-goal.second)){
        auto swapp = [](pll &x){
            swap(x.first, x.second);
        };
        swapp(start);
        swapp(goal);
        foreach(i, supring){
            swapp(i);
        }
    }
    if(start.second>goal.second){
        auto flip = [](pll &x){
            return x = pll(x.first, -x.second);
        };
        flip(start);
        flip(goal);
        foreach(i, supring){
            flip(i);
        }
    }
    if(start.first>goal.first){
        auto flip = [](pll &x){
            return x = pll(-x.first, x.second);
        };
        flip(start);
        flip(goal);
        foreach(i, supring){
            flip(i);
        }
    }
    if(start.second==goal.second){
        foreach(i, supring){
            if(i.second!=start.second)continue;
            if(start.first<=i.first&&i.first<goal.first){
                return abs(start.first-goal.first)*100 + half_cir - 20;
            }
        }
        return abs(start.first-goal.first) * 100;
    }
    vector<ll> memo(n+2, INFLL);
    sort(all(supring));
    foreach(i, supring){
        if(i.first<start.first||goal.first<i.first)continue;
        if(i.second<start.second||goal.second<i.second)continue;
        *lower_bound(all(memo), i.second) = i.second;
    }

    int cnt = 0;

    rep(i, n+2){
        if(memo[i]!=INFLL){
            cnt = i + 1;
        }
    }
    if(goal.second-start.second+1==cnt){
        return (abs(start.first-goal.first)+abs(start.second-goal.second))*100+(cnt-1)*(quot_cir-20)+half_cir-20;
    }
    return (abs(start.first-goal.first)+abs(start.second-goal.second))*100+cnt*(quot_cir-20);
}

int main(){
    input();
    printf("%.20Lf\n", solve());
    return 0;
}


Measured memory_bytes: 4992