// Slower C++ solution:
#include<bits/stdc++.h>

using namespace std;



#define FOR(i,a,b) for(int i = (a); i < (b); i++)

#define RFOR(i,b,a) for(int i = (b) - 1; i >= (a); i--)

#define ITER(it, a) for(typeof(a.begin()) it = a.begin(); it != a.end(); it++)

#define FILL(a, value) memset(a, value, sizeof(a))



#define SZ(a) (int) a.size()

#define ALL(a) a.begin(),a.end()

#define PB push_back

#define MP make_pair



typedef long long LL;

typedef vector<int> VI;

typedef pair<int, int> PII;



const double PI = acos(-1.0);

const LL INF = 1000 * 1000 * 1000 + 7;

const LL LINF = INF * (LL)INF;



const int MAX = 2 * 1000 * 100 + 47;



#define x1 asd

#define y1 dgfg

#define x2 were

#define y2 vcx



struct Fenvic

{

    int T[MAX];

    int n;

    void init(int n1)

    {

        n = n1;

    }

    

    void add(int i, int val)

    {

        for(; i < n; i = i | (i  + 1))

        {

            T[i] = max(T[i], val);

        }

    }

    

    int get(int i)

    {

        int res = 0;

        for(; i >= 0; i = (i & (i + 1)) - 1)

        {

            res = max(res, T[i]);

        }

        

        return res;

    }

} F;



PII A[MAX];

vector<PII> B;

vector<int> T;

int x1, y1, x2, y2, n;



bool inside(int x, int y)

{

    return x >= x1 && y >= y1 && x <= x2 && y <= y2;

}



bool cmp(PII a, PII b)

{

    if (a.second == b.second)

    {

        return a.first < b.first;

    }

    

    return a.second < b.second;

}



int main()

{

	//freopen("in.txt", "r", stdin);

	//freopen("out.txt", "w", stdout);

	ios::sync_with_stdio(false); cin.tie(0);

	cin >> x1 >> y1 >> x2 >> y2 >> n;

	FOR(i,0,n)

	{

	    cin >> A[i].first >> A[i].second;

	}

	

	if (x1 > x2)

	{

	    swap(x1, x2);

	    swap(y1, y2);

	}

	

	if (y1 > y2)

	{

	    y2 = y1 + y1 - y2;

	    FOR(i,0,n)

	    {

	        A[i].second = y1 + y1 - A[i].second;

	    }

	}

	

	FOR(i,0,n)

	{

	    if (!inside(A[i].first, A[i].second)) continue;

	    B.PB(A[i]);

	}

	

	FOR(i,0,SZ(B))

	{

	    T.PB(B[i].first);

	}

	

	sort(ALL(T));

	T.resize(unique(ALL(T)) - T.begin());

	FOR(i,0, SZ(B))

	{

	    B[i].first = lower_bound(ALL(T), B[i].first) - T.begin();    

	}

	

	sort(ALL(B), cmp);

	F.init(SZ(B));

	

	int cnt = 0;

	FOR(i,0, SZ(B))

	{

	    int tmp = F.get(B[i].first);

	    F.add(B[i].first, tmp + 1);

	    cnt = max(cnt, tmp + 1);

	}

	

	//cout << "!" << cnt << endl;

	

	double ans = x2 - x1 + y2 - y1;

	ans *= 100;

	

	if (cnt == min(x2 - x1, y2 - y1) + 1)

	{

	    ans += (-20 + 5 * PI) * (cnt - 1);

	    ans += -20 + 10 * PI;

	}else

	{

	    ans += (-20 + 5 * PI) * cnt;

	}

	

	cout << fixed << setprecision(15) << ans << endl;

}

// Faster C++ solution for the same problem (measured speedup: 5.17520762167718x):
#include<cstdio>

#include<cstring>

#include<algorithm>

#include<cmath>

#define SF scanf

#define PF printf

#define MAXN 200010

#define x first

#define y second

using namespace std;

typedef long long ll;

pair<int,int> p[MAXN];

const double Pi=acos(-1);

int xl,yl,xr,yr;

int fx,fy;

int n;

int st[MAXN];

int main(){

	SF("%d%d%d%d",&xl,&yl,&xr,&yr);

	if(xl>xr)

		fx=-1;

	else

		fx=1;

	if(yl>yr)

		fy=-1;

	else

		fy=1;

	xl*=fx,xr*=fx,yl*=fy,yr*=fy;

	SF("%d",&n);

	for(int i=1;i<=n;i++){

		SF("%d%d",&p[i].x,&p[i].y);

		p[i].x*=fx;

		p[i].y*=fy;

		if(p[i].x<xl||p[i].x>xr||p[i].y<yl||p[i].y>yr){

			n--;

			i--;

			continue;

		}

	}

	sort(p+1,p+1+n);

	int top=0;

	for(int i=1;i<=n;i++){

		if(top==0||st[top]<p[i].y)

			st[++top]=p[i].y;

		else{

			int pos=lower_bound(st+1,st+1+top,p[i].y)-st;

			st[pos]=p[i].y;	

		}

	}

	double ans=(xr-xl)*100.0+(yr-yl)*100.0;

	ans=ans+(double)top*(Pi*5.0-20.0);

	if(top==min(xr-xl+1,yr-yl+1))

		ans+=Pi*5;

	PF("%.11lf",ans);

}