EC_STR_STARTSWITH(3)

πŸ’– ec_str_startswith β€” the Libecoli Programmer's Manual, but make it cute πŸ’–

okay so bestie, we're in section 3 of the Libecoli Programmer's Manual and today's main character is ec_str_startswith ✨ it's giving "does this string start with that thing" and honestly? it's exactly that. no plot twists, no drama, just a little yes-or-no moment πŸŽ€


🌸 NAME 🌸

ec_str_startswith β€” returns 1 if the string starts with the given prefix, periodt πŸ’…


✨ SYNOPSIS ✨

#include <ecoli/string.h>

int ec_str_startswith(
    const char   *s,
    const char   *beginning
);

πŸ¦‹ DESCRIPTION πŸ¦‹

so you hand it two strings β€” s (the string you're checking) and beginning (the prefix you're hoping it starts with) β€” and it tells you whether s starts with beginning. if yes, you get a 1. it's that girl. simple, useful, iconic. no cap 🫢

heads up: the return value is just an int, and per the NAME section it's 1 when the string starts with the given prefix. that's the whole vibe check, iykyk.

πŸ‘‘ SEE ALSO πŸ‘‘

your little friend group of related functions, go say hi πŸ’œ


Copyright (C) 2010-2026 Olivier Matz, Robin Jarry.


and that's the whole page bestie, you ate that πŸ’… thanks for reading, mwah πŸ“

signing off with the classic footer energy: this was libecoli, dated 2026-06-11, and you were reading EC_STR_STARTSWITH(3) the entire time βœ¨πŸŽ€πŸ’–

πŸ“¦ where this page comes from