#include #include "string_common.h" int main() { int r, result1, result2; char *foo = "this is a string"; char *bar = "string"; result1 = endswith(foo, bar); result2 = endswith("string", "asdf"); r = (result1 == 1) && (result2 == 0); printf("%s: endswith\n", r ? "PASS" : "FAIL"); return r; }