Skip to content

Danix29/estructuras-datos

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 

Repository files navigation

C Memory UAH Status


About

Asignatura: Estructuras de Datos · UAH GII · Curso 2025-26

Design and implementation of fundamental data structures in C using dynamic memory allocation. Analysis of time and space complexity for each structure.


Topics covered

Structure Operations Complexity
Linked lists (simple, double, circular) Insert, delete, search, reverse O(n) search, O(1) insert at head
Stacks (LIFO) push, pop, peek, isEmpty O(1) all operations
Queues (FIFO) enqueue, dequeue, front O(1) all operations
Binary trees insert, search, traversals (pre/in/post) O(log n) avg, O(n) worst
Binary search trees insert, delete, search O(log n) avg
Hash tables insert, search, delete, collision handling O(1) avg

Practices

# Name Description
P1 Editorial order system editorial-orders — FIFO queue + LIFO stack with dynamic linked nodes. Order management system for a publishing house

Memory management patterns

// Node allocation
typedef struct Node {
    int data;
    struct Node* next;
} Node;

Node* createNode(int value) {
    Node* node = (Node*)malloc(sizeof(Node));
    if (!node) { perror("malloc failed"); exit(1); }
    node->data = value;
    node->next = NULL;
    return node;
}

// Always free after use
void destroyList(Node* head) {
    Node* current = head;
    while (current) {
        Node* next = current->next;
        free(current);
        current = next;
    }
}

Estructuras de Datos · UAH GII · 2025-26

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors