For this Question: It's the sale season and Ankit bought items worth a total of X rupees. The sale season offer is as follows: <ul><li>if X &le; 100, no discount. </li><li>if 100 < X &le; 1000, discount is 25 rupees. </li><li>if 1000 < X &le; 5000, discount is 100 rupees. </li><li>if X > 5000, discount is 500 rupees. </li></ul>Find the final amount Ankit needs to pay for his shopping.The first line of input will contain a single integer T, denoting the number of test cases. Each test case consists of single line of input containing an integer X.

<b>Constraints</b>
1 &le; T &le; 100
1 &le; X &le; 10000For each test case, output on a new line the final amount Ankit needs to pay for his shopping.Sample Input :
4
15
70
250
1000
Sample Output :
15
70
225
975
Explanation :
<ul><li>Since X &le; 100, there is no discount. </li><li>Here, X = 250. Since 100 < 250 &le; 1000, discount is of 25 rupees. Therefore, Ankit needs to pay 250 − 25 = 225 rupees., I have written this Solution Code: #include <bits/stdc++.h>
#define int long long
#define INF 1e9+7
using namespace std;

void solve(){
    int x;
    cin>>x;
    if (x > 100 and x <= 1000)
        x -= 25;
    else if (x > 1000 and x <= 5000)
        x -= 100;
    else if (x > 5000)
        x -= 500;
    cout<<x<<"\n";
}

signed main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    int t;
    cin>>t;
    for(int i=1;i<=t;++i)
    {
//        cout<<"Case #"<<i<<": ";
        solve();
    }
    return 0;
}, In this Programming Language: C++, Now tell me if this Code is compilable or not?