*Tree Data Structure:* 1. Used to store data in a hierarchical manner. 2. Example: File Explorer uses it maintain Folder & file structure in computer, DOM in HTML, comments 3. Can have any number of children *Basic Terminology:* Root - Topmost node of the tree Parent - A node having successor is a parent of that node Child - A node having ancestor is a child of that node Sibling - nodes of same parent Leaf Node - Node which doesn't have any children *Binary Tree:* A tree where each node can have maximum two child *Properties of Binary Tree:* 1. Maximum nodes at level L : *2^L* 2. Maximum nodes in a tree of height H: *2^H-1*, where H is the number of levels 3. For N nodes, minimum possible height or minimum number of levels are log2(N+1) 4. A binary tree with L leaves has at least log2(N+1)+1 number of levels
Very well teached and explained.. When I saw any video then everytime I satisfied with the content, explaination and the path established for learning the topic. Keep it up.. Name of this channel is Right... Apna college
#Apna college Sir/ Mam please make a video to how to practice questions from where to get question where to practice for beginners who have learned upto oops so that we have grip on previous topics Those who think a video must be made on this please like this comment so it get noticed
some of topices in binary tree were not taught such as implementation of binarytree here is my code for that #include using namespace std; template class BinaryTreeNode{ public: T data; BinaryTreeNode* left; BinaryTreeNode* right;
BinaryTreeNode(T data){ this->data = data; left = NULL; right = NULL; }
kindly provides notes as soon as possible , because it gets very difficult while we are revising( and we have see the whole video again and it is a wastage of time ) ,so aman bhaiya pls upload the notes of all lecture.
no. use a class or a struct, it never matters, except for the default accessibility in a struct is public and in a class is private. But as long as you are explicit in what level of accessibility you're using for your members, it doesn't matter whether a class or a struct is used.
I am a first-year student so I don't have much idea I am studying trees for the first time so I just want to ask why ma'am has not taught trees first before starting with binary trees? Is the tree not of any use? I understood the whole video but I had this thing in my mind.
@@aayushanand8285 wht abt the struct pointer that is being used inside the structure.. Actually I don't use c++ much.. That's why I am facing these issues
@@bitethebyte bro do you know can I have notes of these lectures. because I have observed some notes are missing from the description?? if anyone has idea please let me know.
@@WhatTheFuckAmIDoingNow No, all tools of oops, encapsulation, inheritance, data hiding can be performed in struct also. The only diff is that initially all values in class are private and in struct are public.
*Tree Data Structure:*
1. Used to store data in a hierarchical manner.
2. Example: File Explorer uses it maintain Folder & file structure in computer, DOM in HTML, comments
3. Can have any number of children
*Basic Terminology:*
Root - Topmost node of the tree
Parent - A node having successor is a parent of that node
Child - A node having ancestor is a child of that node
Sibling - nodes of same parent
Leaf Node - Node which doesn't have any children
*Binary Tree:*
A tree where each node can have maximum two child
*Properties of Binary Tree:*
1. Maximum nodes at level L : *2^L*
2. Maximum nodes in a tree of height H: *2^H-1*, where H is the number of levels
3. For N nodes, minimum possible height or minimum number of levels are log2(N+1)
4. A binary tree with L leaves has at least log2(N+1)+1 number of levels
I love how she is trying her Best to give a Example which is " Professional " and " Not Hard to Understand " ❤️❤️
Bhai padh le pyar mohhobat ke chakar mai mat padh
@@NikhilYadav-co5sc true 😂
Very well teached and explained..
When I saw any video then everytime I satisfied with the content, explaination and the path established for learning the topic.
Keep it up..
Name of this channel is Right...
Apna college
Dii aap sab se acha samjhate ho❤️
Ap ka samjna ka andaz Kamal ka a
Thanku soo much Bhaiya ji & Sir ji 🙏🏻 & Maam ji
wow great explain didi
#Apna college
Sir/ Mam please make a video to how to practice questions from where to get question where to practice for beginners who have learned upto oops so that we have grip on previous topics
Those who think a video must be made on this please like this comment so it get noticed
try questions on coding ninjas, because they are free and selected question , after doing those question you can focus on competitions or development
This is my favorite data structures
Family hierarchy is the best example for tree☺
Binary tree is the best example of two child policy 😂😅
best best content love from pakistan
so good tech...
Happy Birthday Aman bhaiya🎂🎉🎉🎂🎉🎉🎂🎉
Here we use level from 0 but in maximum nodes formula is assuming level from 1 it has to be 2^(h+1)-1 if root node is at level 0.
no levels start from 1🥲
Can't we use class for creating a node instead of struct as we done in the past lectures like linked list, stack, queue etc.
Amazing i create a tree first time and i amazes with their teaching style and really helpful for my exams thank didi
some of topices in binary tree were not taught
such as implementation of binarytree
here is my code for that
#include
using namespace std;
template
class BinaryTreeNode{
public:
T data;
BinaryTreeNode* left;
BinaryTreeNode* right;
BinaryTreeNode(T data){
this->data = data;
left = NULL;
right = NULL;
}
~BinaryTreeNode(){
delete left;
delete right;
}
};
void printLevelWise(BinaryTreeNode* root){
if(root == NULL){
return;
}
cout
A binary tree with L leaves has at least log2(L) + 1 number of levels. Correction for point 4 in properties.
nahi bhai
ha bhai
yeah
no she is right where L = log2(n+1)
min levels= L+1
so min levels= log2(n+1)+1
Thank u so much👍👍👍♥️♥️♥️♥️♥️♥️♥️🥰
kindly provides notes as soon as possible , because it gets very difficult while we are revising( and we have see the whole video again and it is a wastage of time ) ,so aman bhaiya pls upload the notes of all lecture.
Thank you Didi 😊🙏💐
This Man Is Going Crazy Keep It Up 😆 Thanks You So Much For All The Lectures❤️🙏
Thank u didi😄
I love you ma'am 💗
0:30
while(1){
folder ke andar folder
}
ye technique to mai wo wali videos chupane k liye karta hu ;)
finally binary tree aa gaya
A powerful data structure is coming
Too nice explained!
CHALO TREE TO UGG GAYA AB FRUITS AANE BAAKI HAI ❤️❤️😎😎😀😀
👍👍🙏🙏🙏🙏🙏🎉🎉🔥❤️❤️
Wooo
I like the way which she is explaining
Why are we not using class in C++ to create Binary tree???
Why are we using structure instead of class ???
you can use class dude
Didi, struct word is not been taught by you in past,plz explain it. Is it similar to class???
yess.... its very much similar...
What is struct?
Sir starting music is a very irritating one.
But overall thanks for this playlist 😍😍😍
Ab to PHOD DENGE 😁
How will take input form user in BST
struct Node
{
/* data */
int data;
struct Node* left;
struct Node* right;
int data;
Node* left;
Node* right
};
What is difference between both of these
Same question
@@kumarivandana1554 Hey finally found there is no btw them ??
The only difference is you have nt mentioned the ptr data type which is struc in the second case.
the only difference is if(condition){
//single action
}
vs
if(condition) /*single action*/ ;
in short , no significant difference
both are same its just we have already defined data left right using struct so we're omiting it afterwards
hope it helped
Will using class instead of struct make any difference?
no. use a class or a struct, it never matters, except for the default accessibility in a struct is public and in a class is private. But as long as you are explicit in what level of accessibility you're using for your members, it doesn't matter whether a class or a struct is used.
its doesnt matter . since class is OOPS so its preffered mostly
In the fourth property, N means the number of nodes that have exactly two child nodes. There is a property that says L = N + 1.
thanks man for this, was getting confused
But you have missed an extra condition that the binary tree should consist either 0 or 2 nodes only
Why we use binary tree??
oo shit m phlyy e bht miss kr diya or ab 25 koo phr shadi hahahah
Do we need to know application of data structures
ohhh shrdha di aa gayi
A binary tree with L leaves has at least log2(N+1) +1 number of level ,ig N would be L
Tq didi
microsoft bali deede OP
Thank you🙏🙏
PLZZ provide notes 🙏🙏
I am a first-year student so I don't have much idea I am studying trees for the first time so I just want to ask why ma'am has not taught trees first before starting with binary trees? Is the tree not of any use?
I understood the whole video but I had this thing in my mind.
Music is nice ✌️
Thanks
Shraddha mam.....
Ye Microsoft wali didi ne padhaya hai na?
haha
what if more than 3 levels are present in the binary tree
leave that BGM playing throughout the video, on really low volume, it makes it much more engaging...
just do try it out...
❤
If a tree has l leaves ? then how many levels in terms of L ?? 6:47
Rectification : There should be L in place of N
why we using struct here previous we use class can we do same with the help of class
yes
why use struct in a c++ video, one must try to use class as much as possible to get familiar with oops properties.
not much difference bro
@@aayushanand8285 bhai can you provide the code using class
@@Shourya_performs just replace the struct keyword with class keyword....and write everything as public....thats it
@@aayushanand8285 wht abt the struct pointer that is being used inside the structure..
Actually I don't use c++ much.. That's why I am facing these issues
@@Shourya_performs you only would require the class/ structure name ...no struct keyword required in c++
you see any error in the 4th property?
yes, for x leaves, minimum no. of levels L = Log(x) + 1, Log having base as 2.
Sir many lecture don't have notes linked with it
Why initialise right and left as Null?
because at that time we are only creating a single node but with two pointer so null is given to complete the node structure
Plz topic wise playlist banado bhaiya
class se kyu nhi kiyaa
Why notes of tree is not uploaded.please anyone reply.and if it is uploaded then where.
I'm here to understand binary tree because in codechef long challenge may there are 3 questions of trees and I really want to do at least one of them
Hiii,I am Biswaranjan from BBSR
your comment told my Heart word.
Today I am here for same purpose...
@@rxcreativity8441 😂 later I realised that those questions are not of binary tree :( as there are more than two child in those questions
Then what to do, I mean any data structure available or any method or use 🧠 to solve... 😂😂Bro any idea 💡 to solve🙄 which is HELPFUL
@@sleepypanda7172 ISS ko sove kiaa?🙄 My only partially AC...
@@rxcreativity8441 with ISS,same problem
This is wrong therr is a difference between height and level
*Property 4 is incorrect please correct it.
kindly upload the notes pls
Didi please share the notes of the lecture
Notes pls
how to find the notes of this lecture ?
guys kisine abhi tak sari class liya hai toh tell me how good this course is pllssss
Yeh course bhi acha hai
Yeh log video late dalte hai aur topic ko jldi finish krte hai .
CodewithHarry se bhi pdh skte ho
@@bitethebyte thanks bro
@@bitethebyte bro do you know can I have notes of these lectures. because I have observed some notes are missing from the description?? if anyone has idea please let me know.
Do anyone know we're will i find notes
Sir full stack developer course ka link dijiye na please🙏🙏🙏🙏🙏
are you speaking?
Notes nhi h sur please upload
Avl tree link
Shraddhha didi is best
How can represent such data in the console?
Englishhhhhhhhhhhhhhhhhhhh
Cause gud vdooo
What's a struct ???
it can hold different data types they work same as class bas ye data hide nahi karte if u want to use classes instead so you can do that too
@@zainulkhan8381 😊 thanks
IN NSUT STUDENTS DONT EXIST IN THE HIERARCHY
Is she Shraddha teaching this?
yes
geeksforgeeks ka utha ke chipka diya 🤣🤣
Does anyone know what is that struct thing?
It's copy paste of class, the only difference is of some properties like encapsulation, inheritance are available only in class but not in structure.
@@WhatTheFuckAmIDoingNow I had found out. Thanks
@@piyushverma8207 👍👍
@@WhatTheFuckAmIDoingNow No, all tools of oops, encapsulation, inheritance, data hiding can be performed in struct also. The only diff is that initially all values in class are private and in struct are public.
@@gauravupreti9340 manually or by some sintax ??
Ma'am plzz pin the note
While writing "bits/stdc++.h " header file,my compiler is showing the error
do it in vs code with all extensions installed of MINGW gcc complier
1:00
C language padhaai na
commenting for algorithm lol
Ma panner khaunga
Thanks
1:00