From 220534453eecc2c07ad710d72268aafd20b83138 Mon Sep 17 00:00:00 2001 From: joe Date: Fri, 8 May 2015 23:07:47 -0400 Subject: initial commit --- str_start.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 str_start.c (limited to 'str_start.c') diff --git a/str_start.c b/str_start.c new file mode 100644 index 0000000..017efc7 --- /dev/null +++ b/str_start.c @@ -0,0 +1,15 @@ +/* Public domain. */ + +#include "str.h" + +int str_start(register const char *s,register const char *t) +{ + register char x; + + for (;;) { + x = *t++; if (!x) return 1; if (x != *s++) return 0; + x = *t++; if (!x) return 1; if (x != *s++) return 0; + x = *t++; if (!x) return 1; if (x != *s++) return 0; + x = *t++; if (!x) return 1; if (x != *s++) return 0; + } +} -- cgit v1.2.3