Login
Register
@
Dark Mode
Profile
Edit my Profile
Messages
My favorites
Register
Activity
Q&A
Questions
Unanswered
Tags
Subjects
Users
Ask
Previous Years
Blogs
New Blog
Exams
Dark Mode
betweenB trees and B+ trees,which one is suited for random and which one is suited for sequential access??
Akriti sood
asked
in
Databases
Jan 11, 2017
1,119
views
0
votes
0
votes
between B trees and B+ trees,which one is suited for random and which one is suited for sequential access??
please explain
databases
binary-tree
Akriti sood
asked
in
Databases
Jan 11, 2017
by
Akriti sood
1.1k
views
answer
comment
Follow
share this
share
0 Comments
Please
log in
or
register
to add a comment.
Please
log in
or
register
to answer this question.
1
Answer
2
votes
2
votes
Best answer
Both B and B+ trees are pratical implementations of sorted file organisation. I am not sure what you mean by sequential access. But as the records are sorted they can be accessed in sequence. And in B+ trees all leaf nodes are linked and they contain all index key values and record pointers. Hence they are perfect for range queries. for eg where salary between 1000000 and 200000.
For quick random access on the other hashed file organisation is best suited.
Kaushik.P.E
answered
Jan 11, 2017
selected
Jan 11, 2017
by
Akriti sood
by
Kaushik.P.E
comment
Follow
share this
4 Comments
by
Sushant Gokhale
commented
Jan 14, 2017
reply
Follow
share this
In B+ trees, if the searching is done on the element(s) that are indexed using B+ tree, B+ tree definitely gives better performance.
Else, its difficult to compare.
0
0
by
Sushant Gokhale
commented
Jan 14, 2017
reply
Follow
share this
Also, hasing may give bad performance as compared to B trees. Depends upon how hashing is implemented i.e. chaining may give as good performance as B trees.
0
0
by
Kaushik.P.E
commented
Jan 15, 2017
reply
Follow
share this
If the hashing algorithm used uniformly distributes the data such that minimal conflicts occurs then the elements can be accessed in O(1). And chaining is used to resolve conflicts in hashing. Dynamic and extensible hashing enables the hash bucket to grow dynamically eliminating conflict all together. So hashed file organisation is best suited for random access.
0
0
by
Sushant Gokhale
commented
Jan 15, 2017
reply
Follow
share this
is it practically possible to distribute uniformly? I mean I am just asking :) . Yes, but atleast therotically, its O(1)
0
0
Please
log in
or
register
to add a comment.
← Previous
Next →
← Previous in category
Next in category →
Related questions
0
votes
0
votes
0
answers
1
M.Zain
asked
in
Digital Logic
Dec 30, 2022
564
views
A sequential circuit has two D flip-flops, two inputs x and y, and one output Z is specified by the following next-state and output equations A(t+1) = xy’ + x B B(t+1) = xA +xB’ Z = A (a) Draw the logic diagram of the circuit. (b) List the state table for the sequential circuit. (c) Draw the corresponding state diagram.
M.Zain
asked
in
Digital Logic
Dec 30, 2022
by
M.Zain
564
views
digital-logic
sequential-circuit
output
0
votes
0
votes
1
answer
2
aditi19
asked
in
Databases
Nov 23, 2018
401
views
B+ Trees
can anyone share some good resources fot B+ tree deletion?
aditi19
asked
in
Databases
Nov 23, 2018
by
aditi19
401
views
databases
binary-tree
indexing
multilevel
0
votes
0
votes
1
answer
3
qweas8671
asked
in
DS
Jul 3, 2022
627
views
For which of the following does there exist a tree satisfying the specified constraints? (a) A binary tree with 65 leaves and height 6. (b) A binary tree with 33 leaves and height 5.
qweas8671
asked
in
DS
Jul 3, 2022
by
qweas8671
627
views
binary-tree
3
votes
3
votes
2
answers
4
Warlock lord
asked
in
Databases
Aug 28, 2017
643
views
Trees
Can somebody please list out the main advantages of B trees, B+ trees and Binary Search Trees over each other?
Warlock lord
asked
in
Databases
Aug 28, 2017
by
Warlock lord
643
views
databases
binary-tree
Subscribe to GATE CSE 2024 Test Series
Subscribe to GO Classes for GATE CSE 2024
Quick search syntax
tags
tag:apple
author
user:martin
title
title:apple
content
content:apple
exclude
-tag:apple
force match
+apple
views
views:100
score
score:10
answers
answers:2
is accepted
isaccepted:true
is closed
isclosed:true
Recent Posts
Post GATE 2024 Guidance [Counseling tips and resources]
GATE CSE 2024 Result Responses
[Project Contest] Pytorch backend support for MLCommons Cpp Inference implementation
Participating in MLCommons Inference v4.0 submission (deadline is February 23 12pm IST)
IIITH PGEE 2024 Test Series by GO Classes
Subjects
All categories
General Aptitude
(3.5k)
Engineering Mathematics
(10.4k)
Digital Logic
(3.6k)
Programming and DS
(6.2k)
Algorithms
(4.8k)
Theory of Computation
(6.9k)
Compiler Design
(2.5k)
Operating System
(5.2k)
Databases
(4.8k)
CO and Architecture
(4.0k)
Computer Networks
(4.9k)
Artificial Intelligence
(79)
Machine Learning
(48)
Data Mining and Warehousing
(25)
Non GATE
(1.4k)
Others
(2.7k)
Admissions
(683)
Exam Queries
(1.6k)
Tier 1 Placement Questions
(17)
Job Queries
(80)
Projects
(11)
Unknown Category
(870)
64.3k
questions
77.9k
answers
243k
comments
79.7k
users
Recent Blog Comments
Hlo I'm Rupesh I got AIR 3485 in gate CS and AIR...
@Ajay Sasank here is the direct link...
Thank you for the post didi My GATE 2023 & 2024...
I Hope it helps 😊
Today's best post I seen thank you for motivation
Twitter
WhatsApp
Facebook
Reddit
LinkedIn
Email
Link Copied!
Copy