#include using namespace std; int main(){ int A; cin >> A; A -= 7; if(A<=7){ cout << -1 << endl; }else{ cout << A << endl; } return 0; }