libft
Loading...
Searching...
No Matches
Functions
ft_array.c File Reference

Implementation of pointer and integer array utilities. More...

#include "libft.h"
+ Include dependency graph for ft_array.c:

Functions

size_t ft_arraysize (void **array)
 Returns the number of elements in a NULL-terminated array.
 
char ** ft_copy_strarray (char **array)
 Creates a deep copy of a NULL-terminated string array.
 
void ft_free_array (void **array)
 Frees a NULL-terminated array.
 
void ft_free_array_size (void **array, size_t size)
 Frees an array of pointers with a known size.
 
bool ft_is_array_sorted (const int *array, size_t size)
 Checks if an array of integers is sorted in ascending order.
 
int ft_putintarray (int *array, int size)
 Prints an array of integers to standard output.
 

Detailed Description

Implementation of pointer and integer array utilities.

Author
Toonsa
Date
2025/04/04

This file is part of the libft project and implements helper functions for working with dynamically allocated arrays:

All functions are designed to be memory-safe and easy to use in generic contexts such as CLI tools, parsers, or game engines.