Majority Element | Leetcode 169 |Moore's voting algorithm | Top 150 interview question series

  Рет қаралды 12,624

Technosage

Technosage

Жыл бұрын

Top 150 interview question series
Majority Element
Leetcode problem number 169
JAVA interview programming playlist:
• Interview Programming ...
Git Repo:
github.com/Technosagelearning...

Пікірлер: 38
@sriramongrind
@sriramongrind 9 ай бұрын
Sister the way you explaining blows my mind don't stop teaching you are so good !
@manishjeena6325
@manishjeena6325 Жыл бұрын
I appreciate your way of explaining.....thank you❤🙏
@JaiShriiiiRam
@JaiShriiiiRam 10 ай бұрын
Thank you so much mam, for such simple and accurate explaination.
@adolfocarrillo248
@adolfocarrillo248 6 ай бұрын
But the algorithm is limited to work only if two different elements appears on the array, for more than 2 different elements it won't work. It's kind of restricted functionality.
@sppatro9477
@sppatro9477 6 ай бұрын
Yes so then what's the solution?
@sppatro9477
@sppatro9477 6 ай бұрын
If you know then please reply
@AnjaliYadav-qv4sb
@AnjaliYadav-qv4sb Ай бұрын
it is very useful...thank you
@nazim4525
@nazim4525 Жыл бұрын
Awesome 👍👍👍👍 mam
@iam_phani
@iam_phani 10 ай бұрын
A big shout out to you Mam. You made topics clear, simple and explanations were on point. A big thank you for all your efforts. If time permits, I humbly request you to please continue the 150 interview leetcode problems.
@TechnosageLearning
@TechnosageLearning 10 ай бұрын
Hey..i will continue the series very soon..stay tuned
@Harshal-dk2kr
@Harshal-dk2kr 4 ай бұрын
will there will be only 2 types of elements in the array ... suppose [1,1,2,3,0,1] here it is 4 diffetnet element ...so what will be output for it.. and 2 or 3 will not try to decrese their point instead of against 1 ..
@AbhayKumar-xp3dy
@AbhayKumar-xp3dy 5 ай бұрын
Hey these videos are really helping me .... can you please complete these 150 sheets playlist , turn out to best resource for me till now. please🙂🙂
@ahmadfarhadghafoori3369
@ahmadfarhadghafoori3369 Ай бұрын
This is only works for these two examples. If the the elements of the array getting longer it won't work.
@krutarthpatel7373
@krutarthpatel7373 2 ай бұрын
best
@purushothamanr.bemechanica3288
@purushothamanr.bemechanica3288 Жыл бұрын
good
@Nonsense675
@Nonsense675 4 ай бұрын
Hi I'm really grateful for this highly self explanatory piece, one point that I am in need of clarification: the input is supposed to be 'non-zero', , is that correct please ?
@umeshkumarmahato5234
@umeshkumarmahato5234 9 ай бұрын
please continue this series
@TechnosageLearning
@TechnosageLearning 9 ай бұрын
Sure 😊
@himanshupokhariya9125
@himanshupokhariya9125 4 ай бұрын
[6,5,5] on that test case answer will be would could you tell me why ??
@mayankarora5345
@mayankarora5345 2 ай бұрын
Mam,given example me '3' ka count 1 ayya h lekin apne ko more than '1'(n/2) chaiye tha , apne ko pta h ki '3' total 2 times h lekin question m kese pta chla ki 3 more than 1(n/2) times h , kioki last m to count '1' hi bachha tha, mtlb usne compare kese kiya length se?
@nazim4525
@nazim4525 Жыл бұрын
Please mam you continue solve LEETCODE questions
@TechnosageLearning
@TechnosageLearning Жыл бұрын
Hi..Will upload videos very soon..
@nazim4525
@nazim4525 Жыл бұрын
@@TechnosageLearning One day your youtube channel will increase a lot of subscribers
@TechnosageLearning
@TechnosageLearning Жыл бұрын
Thank you🙏
@mdayazalam3132
@mdayazalam3132 10 ай бұрын
Mam please upload the Leetcode question no 238 Product of Array Except Self
@ujjwaldas2302
@ujjwaldas2302 17 күн бұрын
you dint verified the case that majority element should be more the n/2 ????
@Bagulaff
@Bagulaff Жыл бұрын
Sir muje VMware me job Leni hai to uske liye kya kya karna padega
@sgautam6468
@sgautam6468 3 ай бұрын
The solution does not work for different arrays.
@yash_14h
@yash_14h 9 ай бұрын
Mam why there are only three types of numbers.?? In array 😢
@TechnosageLearning
@TechnosageLearning 9 ай бұрын
That is only an example..you can take any type of numbers
@GauravRaj-bi9kg
@GauravRaj-bi9kg 20 күн бұрын
why u have stop the series you may complete it all plzzzzzzzzzz
@TechnosageLearning
@TechnosageLearning 20 күн бұрын
Hi Starting very soon..working on it..Please stay tuned
@GauravRaj-bi9kg
@GauravRaj-bi9kg 20 күн бұрын
@@TechnosageLearning as soon as possible am waiting
@soumyabrajwasi845
@soumyabrajwasi845 Жыл бұрын
it fails when arr is - 3,3,4
@TechnosageLearning
@TechnosageLearning Жыл бұрын
No its not failing ..in this case,majority element is 3 and output is also 3..you can try the code from git repo..You might be missing something
@niggaswildin
@niggaswildin 9 ай бұрын
I'm a beginner. After what topics should i learn time and space complexity maam, also i wrote this code and got the answer: class Solution { public int majorityElement(int[] nums) { int n = nums.length; for(int i=0;i
Rotate Array | Leetcode 189 | Top 150 interview question series
11:41
아이스크림으로 체감되는 요즘 물가
00:16
진영민yeongmin
Рет қаралды 23 МЛН
ОСКАР ИСПОРТИЛ ДЖОНИ ЖИЗНЬ 😢 @lenta_com
01:01
Can You Draw A PERFECTLY Dotted Line?
00:55
Stokes Twins
Рет қаралды 100 МЛН
MEGA BOXES ARE BACK!!!
08:53
Brawl Stars
Рет қаралды 36 МЛН
Leetcode 46. Permutations : Introduction to backtracking
10:06
ComputerBread
Рет қаралды 88 М.
Majority element | Leetcode #169
7:13
Techdose
Рет қаралды 48 М.
Valid Anagram | LeetCode problem 242
8:33
Technosage
Рет қаралды 11 М.
Search Insert Position | Leetcode 35
15:30
Technosage
Рет қаралды 8 М.
Giant numbers
7:27
stuff | An abridged guide to interesting things
Рет қаралды 1,2 М.
Majority Element | leetcode 169 | Hindi
11:23
Codebix
Рет қаралды 4,3 М.
Blue Mobile 📲 Best For Long Audio Call 📞 💙
0:41
Tech Official
Рет қаралды 1 МЛН
⚡️Супер БЫСТРАЯ Зарядка | Проверка
1:00