HTML & JS
#include<iostream>
using namespace std;
int main()
{
    int a,b;
            cin>>a>>b;
 	    int n=a-b;
 	    if((n%10)!=9){cout<<n+1<<endl;}
 	    
 	    	      else{cout<<n-1<<endl;}
 	    	     
 	      
 	   
return 0;
}

Generated URL:

Output:

-4
Report Bug