summaryrefslogblamecommitdiffstats
path: root/mat/domace_naloge/2/d=nx.c
blob: 8f9138773718d648f13e57da19197ae48f159bf9 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12
13












                                                                                                                
#include <stdio.h>
long long unsigned int d(long long unsigned int n) { return (n*(n-3))/2; }
long long unsigned int x(long long unsigned int n) { return (n/2)-(3/2); }
int main() {
	long long unsigned int n = 3;
	while (n < 420696969) {
		if (d(n) != n*x(n)) {
			fprintf(stdout, "%lld-kotnik! d(n)=%lld, x(n)=%lld, n*x=%lld\n", n, d(n), x(n), n*x(n));
		}
		n = n+2;
	}
}