This commit is contained in:
2026-04-30 23:42:34 +02:00
commit 6ccc96b2fe
16 changed files with 32397 additions and 0 deletions
@@ -0,0 +1,15 @@
CC=gcc
CFLAGS=-Wall -Wextra -Werror -fsanitize=address -g -pedantic
SRCS=dlist.c main.c
OBJS=$(SRCS:.c=.o)
TARGET=dlist
all: $(TARGET)
$(TARGET): $(OBJS)
$(CC) $(CFLAGS) -o $@ $^
clean:
$(RM) -r $(TARGET) $(OBJS)
@@ -0,0 +1,63 @@
#include "dlist.h"
#include <stdio.h>
#include <stdlib.h>
struct dlist *dlist_init(void)
{
// TODO
return NULL;
}
void dlist_clear(struct dlist *list)
{
}
size_t dlist_length(struct dlist *l)
{
// TODO
return 0;
}
void dlist_push_front(struct dlist *l, int data)
{
// TODO
}
void dlist_push_back(struct dlist *l, int data)
{
// TODO
}
void dlist_remove(struct dlist *list, int data)
{
// TODO
}
struct dlist *dlist_from_str(char *str)
{
// TODO
return NULL;
}
struct node *dlist_find(struct dlist *list, int data)
{
// TODO
return NULL;
}
void dlist_print(struct dlist *l)
{
// TODO
}
void dlist_concat(struct dlist *l1, struct dlist *l2)
{
// TODO
}
void dlist_insert(struct dlist *l, int data, int i)
{
// TODO
}
@@ -0,0 +1,8 @@
// This file will not be tested, you can modify it.
#include "dlist.h"
int main(void)
{
// TODO
}