#include<stdio.h>
int main(void){
	long long int i,a,c;
	scanf("%lld",&a);
	c = (a/3+a/5)*2;
	printf("%lld\n",c);
	return 0;
}