#include<bits/stdc++.h>
using namespace std;
#define yes cout<<"YES"<<endl
#define no cout<<"NO"<<endl
#define prime_number[21]={11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97}
///POLICY BASED DATA STRUCTURE..
///order_of_key return number of element which are strictly greater/smaller than x..
///find_by_order return ans iterator corresponding to the xth position of the set..
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
using namespace __gnu_pbds;
void fast(){
ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0);
}
int main(){
fast();
int tc=1;
// cin>>tc;
int h=1;
while(tc--){
int a;
cin>>a;
if(a%3==0){
cout<<a/3<<endl;
}
else if(a%3==2){
cout<<a/3 +1 <<endl;
}
else{
int k=a/3;
k=(k-1)*3;
int ans=k/3;
cout<<ans+2<<endl;
}
}
}