Language: C++

#include <iostream>
#include <math.h>
#include <algorithm>
#include <vector>
#include <numeric>
#include <string>
using namespace std;
const double PI = acos(-1.0);
const string alp = "abcdefghijklmnopqrstuvwxyz";
const string ALP = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
#define EXIST(s,e) ((s).find(e)!=(s).end())
#define SORT(c) sort((c).begin(),(c).end())
#define FOR(i,a,b) for(int i=(a);i<(b);++i)
#define REP(i,n) FOR(i,0,n)
#define REP1(i,n) FOR(i,1,n+1)
#define SUM(c) accumulate((c).begin(),(c).end(),0)
#define UNIQ(c) (c).erase(unique((c).begin(), (c).end()), (c).end());
#define Yn(b) puts(b?"Yes":"No")
#define YN(b) puts(b?"YES":"NO")

bool isprime(int p) {
  if (p==1) return false;
  FOR(i,2,p) {
    if (p%i==0) return false;
  }
  return true;
}

int main(){
  int n,k;
  long c;
  cin >> n >> k;
  c=0;
  if(k==0){
    cout << n*n;
    return 0;
  }
  FOR(i,k,n+1){
    c+=(n/i)*(i-k);
    if((n%i)-k+1>0){
      c+=(n%i)-k+1;
    }
  }
  cout << c;
  return 0;
}#include <iostream>
#include <math.h>
#include <algorithm>
#include <vector>
#include <numeric>
#include <string>
using namespace std;
const double PI = acos(-1.0);
const string alp = "abcdefghijklmnopqrstuvwxyz";
const string ALP = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
#define EXIST(s,e) ((s).find(e)!=(s).end())
#define SORT(c) sort((c).begin(),(c).end())
#define FOR(i,a,b) for(int i=(a);i<(b);++i)
#define REP(i,n) FOR(i,0,n)
#define REP1(i,n) FOR(i,1,n+1)
#define SUM(c) accumulate((c).begin(),(c).end(),0)
#define UNIQ(c) (c).erase(unique((c).begin(), (c).end()), (c).end());
#define Yn(b) puts(b?"Yes":"No")
#define YN(b) puts(b?"YES":"NO")

bool isprime(int p) {
  if (p==1) return false;
  FOR(i,2,p) {
    if (p%i==0) return false;
  }
  return true;
}

int main(){
  int n,k;
  long long c;
  cin >> n >> k;
  c=0;
  if(k==0){
    cout << n*n;
    return 0;
  }
  FOR(i,k,n+1){
    c+=(n/i)*(i-k);
    if((n%i)-k+1>0){
      c+=(n%i)-k+1;
    }
  }
  cout << c;
  return 0;
}

Compiler output:
a.cc:46:2: error: stray '#' in program
   46 | }#include <iostream>
      |  ^
a.cc:46:3: error: 'include' does not name a type
   46 | }#include <iostream>
      |   ^~~~~~~
a.cc:53:14: error: redefinition of 'const double PI'
   53 | const double PI = acos(-1.0);
      |              ^~
a.cc:8:14: note: 'const double PI' previously defined here
    8 | const double PI = acos(-1.0);
      |              ^~
a.cc:54:14: error: redefinition of 'const std::string alp'
   54 | const string alp = "abcdefghijklmnopqrstuvwxyz";
      |              ^~~
a.cc:9:14: note: 'const std::string alp' previously declared here
    9 | const string alp = "abcdefghijklmnopqrstuvwxyz";
      |              ^~~
a.cc:55:14: error: redefinition of 'const std::string ALP'
   55 | const string ALP = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
      |              ^~~
a.cc:10:14: note: 'const std::string ALP' previously declared here
   10 | const string ALP = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
      |              ^~~
a.cc:66:6: error: redefinition of 'bool isprime(int)'
   66 | bool isprime(int p) {
      |      ^~~~~~~
a.cc:21:6: note: 'bool isprime(int)' previously defined here
   21 | bool isprime(int p) {
      |      ^~~~~~~
a.cc:74:5: error: redefinition of 'int main()'
   74 | int main(){
      |     ^~~~
a.cc:29:5: note: 'int main()' previously defined here
   29 | int main(){
      |     ^~~~