Skip to content

Instantly share code, notes, and snippets.

View AbhishekRaval's full-sized avatar
🎯
Focusing

Abhishek Raval AbhishekRaval

🎯
Focusing
View GitHub Profile
/* Doubly Linked List implementation */
#include<stdio.h>
#include<stdlib.h>
struct Node {
int data;
struct Node* next;
struct Node* prev;
};
@mycodeschool
mycodeschool / BST_InorderSuccessor_CPP.cpp
Last active October 29, 2023 09:20
C++ program to find Inorder successor in a BST
/* C++ program to find Inorder successor in a BST */
#include<iostream>
using namespace std;
struct Node {
int data;
struct Node *left;
struct Node *right;
};
//Function to find some data in the tree
@mycodeschool
mycodeschool / PreorderInorderPostorder_CPP.cpp
Last active May 20, 2024 08:50
Binary tree traversal: Preorder, Inorder, Postorder
/* Binary Tree Traversal - Preorder, Inorder, Postorder */
#include<iostream>
using namespace std;
struct Node {
char data;
struct Node *left;
struct Node *right;
};
/* Binary tree - Level Order Traversal */
#include<iostream>
#include<queue>
using namespace std;
struct Node {
char data;
Node *left;
Node *right;
};
@mycodeschool
mycodeschool / DoublyLinkedList.c
Created November 12, 2013 11:38
Doubly Linked List implementation in C
/* Doubly Linked List implementation */
#include<stdio.h>
#include<stdlib.h>
struct Node {
int data;
struct Node* next;
struct Node* prev;
};