Skip to content

Instantly share code, notes, and snippets.

View raiyansarker's full-sized avatar
💤
Hibernating

Raiyan Sarker raiyansarker

💤
Hibernating
View GitHub Profile
#include <stdio.h>
#define QUEUE_SIZE 100
#define STACK_SIZE 100
#define MAX_CONN 8
int queue[QUEUE_SIZE];
int front = -1, rear = -1;
int stack[STACK_SIZE];
#include <stdio.h>
#include <stdlib.h>
#define MAX 10
typedef struct Node {
int data;
struct Node *next;
} Node;
#include <stdio.h>
#include <stdlib.h>
typedef struct Node {
int data;
struct Node *left, *right;
} Node;
Node* createNode(int data) {
Node* n = (Node*)calloc(1, sizeof(Node));
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <math.h>
#define MAX_SIZE 100
typedef struct Stack {
int arr[MAX_SIZE];
int top;
#include <stdio.h>
#include <stdlib.h>
#define MAX_SIZE 100
typedef struct Stack {
int arr[MAX_SIZE];
int top;
} Stack;
#include <stdio.h>
#include <stdlib.h>
typedef struct Node {
int data;
struct Node *next;
} Node;
void push(Node **head, int data);
int pop(Node **head);
#include <stdio.h>
#include <stdlib.h>
typedef struct Node {
int data;
struct Node *next;
struct Node *prev;
} Node;
void insert_end(Node **head, int data);
#include <stdio.h>
#include <stdlib.h>
typedef struct Node {
int data;
struct Node *next;
} Node;
void insert_end(Node **head, int data);
void insert_begin(Node **head, int data);
#include <stdio.h>
#include <stdlib.h>
typedef struct Node {
int data;
struct Node *next;
} Node;
Node* init();
void insert_end(Node *head, int data);
#include <stdio.h>
#include <stdlib.h> // this is for calloc
typedef struct node {
int x,y;
struct node *next;
} Node;
int main() {
/*