Language: C++

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)

int main(){
    ll K,S;
    cin>>K>>S;
    ll z;
    ll ans=0;
    rep(x,0,K+1){
        rep(y,0,K+1)){
            z = S-x-y;
            if(0<=z&&z<=K)ans++;
        }
    }
    cout<<ans<<endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:11: error: expected primary-expression before numeric constant
   11 |     rep(x,0,K+1){
      |           ^
a.cc:4:37: note: in definition of macro 'rep'
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                     ^~~
a.cc:11:11: error: expected ')' before numeric constant
   11 |     rep(x,0,K+1){
      |           ^
a.cc:4:37: note: in definition of macro 'rep'
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                     ^~~
a.cc:4:33: note: to match this '('
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                 ^
a.cc:11:5: note: in expansion of macro 'rep'
   11 |     rep(x,0,K+1){
      |     ^~~
a.cc:11:13: error: expected primary-expression before 'K'
   11 |     rep(x,0,K+1){
      |             ^
a.cc:4:49: note: in definition of macro 'rep'
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                                 ^~~
a.cc:11:13: error: expected ')' before 'K'
   11 |     rep(x,0,K+1){
      |             ^
a.cc:4:49: note: in definition of macro 'rep'
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                                 ^~~
a.cc:4:45: note: to match this '('
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                             ^
a.cc:11:5: note: in expansion of macro 'rep'
   11 |     rep(x,0,K+1){
      |     ^~~
a.cc:12:15: error: expected primary-expression before numeric constant
   12 |         rep(y,0,K+1)){
      |               ^
a.cc:4:37: note: in definition of macro 'rep'
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                     ^~~
a.cc:12:15: error: expected ')' before numeric constant
   12 |         rep(y,0,K+1)){
      |               ^
a.cc:4:37: note: in definition of macro 'rep'
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                     ^~~
a.cc:4:33: note: to match this '('
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                 ^
a.cc:12:9: note: in expansion of macro 'rep'
   12 |         rep(y,0,K+1)){
      |         ^~~
a.cc:12:17: error: expected primary-expression before 'K'
   12 |         rep(y,0,K+1)){
      |                 ^
a.cc:4:49: note: in definition of macro 'rep'
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                                 ^~~
a.cc:12:17: error: expected ')' before 'K'
   12 |         rep(y,0,K+1)){
      |                 ^
a.cc:4:49: note: in definition of macro 'rep'
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                                 ^~~
a.cc:4:45: note: to match this '('
    4 | #define rep(i,srt,end) for(ll i=(ll srt); i<(ll end); i++)
      |                                             ^
a.cc:12:9: note: in expansion of macro 'rep'
   12 |         rep(y,0,K+1)){
      |         ^~~
a.cc:12:21: error: expected primary-expression before ')' token
   12 |         rep(y,0,K+1)){
      |                     ^