int delete_user(const char *name, User **user_ptr_del) {
    // Delete user from list
    User *curr = *user_ptr_del;
    User *temp = *user_ptr_del;
    // If 1 element in the list

    if (curr->next == NULL) {
        if (strcmp(curr->name, name) == 0) {
            temp = *user_ptr_del;
        } else {
            return 1;
        }
    }

    while (strcmp(curr->next->name, name) != 0 && curr->next != NULL) {
        curr = curr->next;
    }
    // If name does not exist
    if (curr->next == NULL) {
        return 1;
    }
    // If user to be removed is the last one
    if (curr->next->next == NULL) {
        temp = curr->next;
        curr->next = NULL;
    } else {
         // If user to be removed is in the middle of the list
         temp = curr->next;
         curr->next = curr->next->next;
    }
    free(temp);
    return 0;
}
/*
 * From the list pointed to by *user_ptr_del, delete the user
 * with the given name.
 *
 * Return:
 *   - 0 on success.
 *   - 1 if a user with this name does not exist.
 */