#include <bits/stdc++.h>
#define rep(i,n) for(long long i=0; i<n; i++)
#define Rep(i,n) for(long long i=1; i<n; i++)
#define ll long long
#include <math.h>
#include <cmath>
#include <iomanip>
#include <iostream>
#include <numeric>
#include <queue>
#include <set>
#include <vector>


using namespace std;
#define PI acos(-1)




int main(){
    ll N;
    cin>>N;
  
  cout<<2*N*PI<<endl;
  return 0;
}


#include <iostream>
using namespace std;

int main()
{
  int x, coin500, coin5;
  cin >> x;
  coin500 = x / 500;
  x -= coin500 * 500;
  coin5 = x / 5;
  cout << coin500 * 1000 + coin5 * 5 << endl;
  return 0;
}