aboutsummaryrefslogtreecommitdiff
path: root/games/primes/pattern.c
diff options
context:
space:
mode:
authorTony Finch <fanf@FreeBSD.org>2002-10-09 19:38:55 +0000
committerTony Finch <fanf@FreeBSD.org>2002-10-09 19:38:55 +0000
commit9a171f4fc4f19a41e3b1e75d0e67cd206de59537 (patch)
tree3550a410f691d5a377d315fc6ddf06ffb9cd04cd /games/primes/pattern.c
parent5715307f74621e9e2dcde38412eb6dc54b79d8ad (diff)
Style fixes to: #include ordering; use const and static; ANSI functions;
various usage synopses; bogus and/or unnecessary casting; exit values; use LINE_MAX instead of magic numbers; declare extern variables in a header; add $FreeBSD$ where missing. Reviewed by: markm, obrien Obtained from: NetBSD | fanf
Notes
Notes: svn path=/head/; revision=104720
Diffstat (limited to 'games/primes/pattern.c')
-rw-r--r--games/primes/pattern.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/games/primes/pattern.c b/games/primes/pattern.c
index 1d72fb273f80..dff1f4d2d610 100644
--- a/games/primes/pattern.c
+++ b/games/primes/pattern.c
@@ -56,7 +56,9 @@ static const char rcsid[] =
#include <stddef.h>
-char pattern[] = {
+#include "primes.h"
+
+const char pattern[] = {
1,0,0,0,0,0,0,0,1,1,0,1,0,0,1,1,0,0,1,0,1,1,0,1,0,0,1,0,0,1,1,0,0,1,0,1,1,0,0,
1,0,1,0,0,1,0,0,0,1,0,1,1,0,1,1,0,1,0,0,0,0,0,0,1,0,1,0,0,1,1,0,0,0,0,1,1,0,0,
1,0,0,1,0,1,0,0,1,0,0,1,1,0,0,0,0,1,1,0,1,1,0,0,0,0,0,1,0,0,0,0,0,1,0,1,1,0,1,
@@ -443,4 +445,4 @@ char pattern[] = {
0,0,1,1,0,0,0,0,1,1,0,0,1,0,1,0,0,0,0,0,0,1,0,1,1,0,1,1,0,1,0,0,0,1,0,0,1,0,1,
0,0,1,1,0,1,0,0,1,1,0,0,1,0,0,1,0,1,1,0,1,0,0,1,1,0,0,1,0,1,1,0,0,0,0,0,0,0,1
};
-size_t pattern_size = (sizeof(pattern)/sizeof(pattern[0]));
+const size_t pattern_size = (sizeof(pattern)/sizeof(pattern[0]));