<?php

while($line = fgets(STDIN)){
	$n = intval($line);
	if($n <= 0){
		exit();
	}
	$cnt = ($n + 1)*($n*$n + 5*$n + 6)/6;
	
	/*$cnt = 0;
	for($a = 0; $a <= $n; $a++){
		$da = $n - $a;
		$cnt += ($da + 1)*($da + 2)/2;
		
		/*for($b = 0; $b <= $da; $b++){
			$db = $da - $b;
			
			$cnt += $db + 1;
			/*}for($c = 0; $c <= $db && $c <= MAX_INT; $c++){
				$cnt++;
			}
		}
	}*/
	
	echo $cnt."\n";
}