Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- #ifndef DEBUG
- #define DEBUG(...) printf(__VA_ARGS__)
- #endif
- typedef struct Node {
- int val;
- struct Node *next;
- struct Node *prev;
- } node;
- void dodaj(node **head, node **tail, node **half, int val, *brelemenata){
- node *new;
- new = (node *) malloc(sizeof(node));
- if(!new) return;
- new->val = val;
- new->next = *head;
- new->prev = ;
- *head = new;
- (*brelemenata)++;
- }
- void obrisi(node **tail, *brelemenata){
- node *tmp;
- if(!*head) return;
- tmp = (*head)->next;
- free(*head);
- *head = tmp;
- (*brelemenata)--;
- }
- void polprvihnakraj(brelemenata){
- }
- int main() {
- int n, x, k, brelemenata = 0;
- char c;
- node *head = NULL, *tail = NULL, *half = NULL;
- scanf("%d", &n);
- for(int i = 0; i < n; ++i) {
- scanf("%c%d", &c, &x);
- if(c == 'd') {
- } else if(c == 'o') {
- } else if (c == 'p') {
- }
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement