diff --git a/C/p051.c b/C/p051.c index bf6424c..d126aa3 100644 --- a/C/p051.c +++ b/C/p051.c @@ -54,7 +54,7 @@ int main(int argc, char **argv) } free(primes); - + clock_gettime(CLOCK_MONOTONIC, &end); elapsed = (end.tv_sec - start.tv_sec) + (double)(end.tv_nsec - start.tv_nsec) / 1000000000; diff --git a/C/p053.c b/C/p053.c index 75fc4c0..b69045a 100644 --- a/C/p053.c +++ b/C/p053.c @@ -61,7 +61,7 @@ int main(int argc, char **argv) printf("Project Euler, Problem 53\n"); printf("Answer: %d\n", count); - + printf("Elapsed time: %.9lf seconds\n", elapsed); return 0; diff --git a/C/p055.c b/C/p055.c index e4a5a92..0117caa 100644 --- a/C/p055.c +++ b/C/p055.c @@ -57,7 +57,7 @@ int main(int argc, char **argv) printf("Project Euler, Problem 55\n"); printf("Answer: %d\n", count); - + printf("Elapsed time: %.9lf seconds\n", elapsed); return 0; @@ -75,7 +75,7 @@ int is_lychrel(mpz_t n) for(i = 0; i < 50; i++) { mpz_set_ui(reverse, 0); - + /* Find the reverse of the given number.*/ while(mpz_cmp_ui(tmp, 0) > 0) { diff --git a/C/p056.c b/C/p056.c index c40ca4f..314964c 100644 --- a/C/p056.c +++ b/C/p056.c @@ -43,7 +43,7 @@ int main(int argc, char **argv) printf("Project Euler, Problem 56\n"); printf("Answer: %d\n", max); - + printf("Elapsed time: %.9lf seconds\n", elapsed); return 0; diff --git a/C/p057.c b/C/p057.c index bfe11b3..b6da999 100644 --- a/C/p057.c +++ b/C/p057.c @@ -56,7 +56,7 @@ int main(int argc, char **argv) printf("Project Euler, Problem 57\n"); printf("Answer: %d\n", count); - + printf("Elapsed time: %.9lf seconds\n", elapsed); return 0; diff --git a/C/p058.c b/C/p058.c index 9eeeb15..f8bce19 100644 --- a/C/p058.c +++ b/C/p058.c @@ -55,7 +55,7 @@ int main(int argc, char **argv) { count++; } - + i += step; ratio = (double)count / diag; diff --git a/C/p060 b/C/p060 deleted file mode 100755 index 07f349a..0000000 Binary files a/C/p060 and /dev/null differ diff --git a/C/p060.c b/C/p060.c index 4687f17..4e64606 100644 --- a/C/p060.c +++ b/C/p060.c @@ -13,7 +13,7 @@ #define N 10000 int cat(int i, int j); - + int *primes; int main(int argc, char **argv) @@ -94,7 +94,7 @@ int main(int argc, char **argv) printf("Project Euler, Problem 60\n"); printf("Answer: %d\n", n); - + printf("Elapsed time: %.9lf seconds\n", elapsed); return 0;