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
Which one is right ? what will be the right answer assigning 0 to the left edges or right?
Nisha Bharti
asked
in
Algorithms
Nov 26, 2022
597
views
0
votes
0
votes
huffman-code
greedy-algorithm
algorithm-design
Nisha Bharti
asked
in
Algorithms
Nov 26, 2022
by
Nisha Bharti
597
views
answer
comment
Follow
share this
share
4 Comments
Show 2 previous comments
by
Kabir5454
commented
Nov 26, 2022
reply
Follow
share this
yes .but depending on the convention you have used . It is implementation dependent . if i implement the code considering i will put left edge as ‘0’ and right edge as ‘1’ then A will get code as “00” .
0
0
by
Chandrabhan Vishwa 1
commented
Nov 26, 2022
reply
Follow
share this
if nothing is mention then left side children have zero and right side children have 1 if mention then do with corresponding it .
0
0
by
Kabir5454
commented
Nov 26, 2022
reply
Follow
share this
if nothing mention go with the option .
0
0
Please
log in
or
register
to add a comment.
Please
log in
or
register
to answer this question.
1
Answer
0
votes
0
votes
This is purely based on implementation and there is no hard and fast rule for that
Psy Duck
answered
Dec 26, 2022
by
Psy Duck
comment
Follow
share this
0 Comments
Please
log in
or
register
to add a comment.
← Previous
Next →
← Previous in category
Next in category →
Related questions
1
vote
1
vote
1
answer
1
amrit22
asked
in
Algorithms
Sep 24, 2023
634
views
consider the following message BCCABBDDAECCBBAEDDCC find the no of bits requiered for huffman encoding of above message
amrit22
asked
in
Algorithms
Sep 24, 2023
by
amrit22
634
views
algorithms
greedy-algorithm
huffman-code
0
votes
0
votes
1
answer
2
sonalrawat
asked
in
Algorithms
Aug 21, 2023
674
views
We are given a directed graph, represented as an adjacency list, in which each vertex has at least one incoming edge and one outgoing edge. We would like to print out for each vertex j the list of vertices pointing into j. What is the most accurate description of the complexity of computing these quantities in terms of n, the number of vertices, and m, the number of edges? O(n2) O(nm) O(m) O(n)
sonalrawat
asked
in
Algorithms
Aug 21, 2023
by
sonalrawat
674
views
algorithms
time-complexity
11
votes
11
votes
1
answer
3
GO Classes
asked
in
Algorithms
Jan 28
651
views
GO Classes Test Series 2024 | Mock GATE | Test 13 | Question: 42
Consider the following statements related to Huffman's algorithm: $\text{S1:}$ If there is exactly one symbol with a frequency of $1 / 3$, and all other symbols have frequencies strictly less than $1 / 3$, then Huffman's algorithm may ... $\mathrm{S} 1$ is false, but $\mathrm{S} 2$ is true. S1 is false, and S2 is false.
GO Classes
asked
in
Algorithms
Jan 28
by
GO Classes
651
views
goclasses2024-mockgate-13
goclasses
algorithms
greedy-algorithm
huffman-code
2-marks
11
votes
11
votes
1
answer
4
GO Classes
asked
in
Algorithms
Jan 21
866
views
GO Classes Test Series 2024 | Mock GATE | Test 12 | Question: 1
Consider the two statements regarding the Huffman's algorithm - $\text{S1:}$ The character with the highest probability (all probabilities are unique) is guaranteed to be one of the leaves that is closest to the root (i.e it ... $\mathrm{S} 2$ is correct Both are correct statements Both are incorrect statements
GO Classes
asked
in
Algorithms
Jan 21
by
GO Classes
866
views
goclasses2024-mockgate-12
goclasses
algorithms
greedy-algorithm
huffman-code
1-mark
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
(684)
Exam Queries
(1.6k)
Tier 1 Placement Questions
(17)
Job Queries
(80)
Projects
(11)
Unknown Category
(870)
64.3k
questions
77.9k
answers
244k
comments
80.0k
users
Recent Blog Comments
category ?
Hi @Arjun sir, I have obtained a score of 591 in ...
download here
Can you please tell about IIT-H mtech CSE self...
Please add your admission queries here:...
Twitter
WhatsApp
Facebook
Reddit
LinkedIn
Email
Link Copied!
Copy