import java.util.Scanner;
public class Main {
  public static void main(String[] args){
    Scanner scan = new Scanner(System.in);
    int n = scan.nextInt();
    int l = scan.nextInt();
    int bited = 300;
    int sum = 0;
    for(int i = l; i < l + n; i++){
      sum += i;
      if(Math.abs(i) < Math.abs(bited)){
        bited = i;
      }
    }
    System.out.println(sum - bited);
  }
} import java.util.Scanner; Scanner java.util public class Main {
  public static void main(String[] args){
    Scanner scan = new Scanner(System.in);
    int n = scan.nextInt();
    int l = scan.nextInt();
    int bited = 300;
    int sum = 0;
    for(int i = l; i < l + n; i++){
      sum += i;
      if(Math.abs(i) < Math.abs(bited)){
        bited = i;
      }
    }
    System.out.println(sum - bited);
  }
} Main public static void main(String[] args){
    Scanner scan = new Scanner(System.in);
    int n = scan.nextInt();
    int l = scan.nextInt();
    int bited = 300;
    int sum = 0;
    for(int i = l; i < l + n; i++){
      sum += i;
      if(Math.abs(i) < Math.abs(bited)){
        bited = i;
      }
    }
    System.out.println(sum - bited);
  } main {
    Scanner scan = new Scanner(System.in);
    int n = scan.nextInt();
    int l = scan.nextInt();
    int bited = 300;
    int sum = 0;
    for(int i = l; i < l + n; i++){
      sum += i;
      if(Math.abs(i) < Math.abs(bited)){
        bited = i;
      }
    }
    System.out.println(sum - bited);
  } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int n = scan.nextInt(); n scan.nextInt() scan.nextInt scan int l = scan.nextInt(); l scan.nextInt() scan.nextInt scan int bited = 300; bited 300 int sum = 0; sum 0 for(int i = l; i < l + n; i++){
      sum += i;
      if(Math.abs(i) < Math.abs(bited)){
        bited = i;
      }
    } int i = l; int i = l; i l i < l + n i l + n l n i++ i++ i {
      sum += i;
      if(Math.abs(i) < Math.abs(bited)){
        bited = i;
      }
    } {
      sum += i;
      if(Math.abs(i) < Math.abs(bited)){
        bited = i;
      }
    } sum += i sum i if(Math.abs(i) < Math.abs(bited)){
        bited = i;
      } Math.abs(i) < Math.abs(bited) Math.abs(i) Math.abs Math i Math.abs(bited) Math.abs Math bited {
        bited = i;
      } bited = i bited i System.out.println(sum - bited) System.out.println System.out System System.out sum - bited sum bited String[] args args public class Main {
  public static void main(String[] args){
    Scanner scan = new Scanner(System.in);
    int n = scan.nextInt();
    int l = scan.nextInt();
    int bited = 300;
    int sum = 0;
    for(int i = l; i < l + n; i++){
      sum += i;
      if(Math.abs(i) < Math.abs(bited)){
        bited = i;
      }
    }
    System.out.println(sum - bited);
  }
} public class Main {
  public static void main(String[] args){
    Scanner scan = new Scanner(System.in);
    int n = scan.nextInt();
    int l = scan.nextInt();
    int bited = 300;
    int sum = 0;
    for(int i = l; i < l + n; i++){
      sum += i;
      if(Math.abs(i) < Math.abs(bited)){
        bited = i;
      }
    }
    System.out.println(sum - bited);
  }
} Main
import java.util.Scanner;
public class Main {
  public static void main(String[] args){
    Scanner scan = new Scanner(System.in);
    int n = scan.nextInt();
    int l = scan.nextInt();
    int bited = 300;
    int sum = 0;
    for(int i = l; i < l + n; i++){
      sum += i;
      if(Math.abs(i) < Math.abs(bited)){
        bited = i;
      }
    }
    System.out.println(sum - bited);
  }
}