#include<iostream> using namespace std; int main(){ int d; cin>>d; if(d<=5){ cout<<d+2; }else{ cout<<d+2-7; } return 0; }