Тёмный
No video :(

Bigger Is Greater HackerRank Solution 

JAVAAID - Coding Interview Preparation
Подписаться 37 тыс.
Просмотров 16 тыс.
50% 1

Опубликовано:

 

22 авг 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 51   
@JavaAidTutorials
@JavaAidTutorials 5 лет назад
JAVAAID community: RU-vid recently changed the way they monetize my content. My channel now needs 1,000 subscribers so it would be awesome if you could show your support by both watching my videos and subscribing to my channel if you haven’t already done so. Monetizing my videos allows me to invest back into the channel with new equipment so a small gesture from you goes a huge way for me. Many thanks for your support!
@smahidharreddy
@smahidharreddy 5 лет назад
Hi Kanahaiya, Thanks for the video. your solution is good and pretty simple to understand. Could you also make video on Queens Attack II.
@JavaAidTutorials
@JavaAidTutorials 5 лет назад
​@@smahidharreddy Thanks for your compliment. Will try to make a tutorial on this on future if possible. It takes a lot of effort and time to make the good content and after that, very fewer people will watch then it does not motivate the creator at all. so currently I am focusing on the questions which most of the people tried but did not able to solve due to the right algorithm or approach. If there are too many people who want the solution for Queen attack problem will definitely make a video tutorial on this very soon. but if you need help to solve this, I can.
@navinchainani4721
@navinchainani4721 4 года назад
First i don't understand programming i finds it too difficult then i started coding from u RU-vid channel after that i understand coding very nicely
@JavaAidTutorials
@JavaAidTutorials 4 года назад
thanks for the such a nice compliment.🙂 I am glad, you are learning something from our channel.
@GG-sw9vm
@GG-sw9vm Год назад
Does this work with "dkhc", with the logic, it will be d k h c, since d < k, we swap out c which is the smallest character to the right, now it becomes c k h d, after sorting c d h k which is wrong.
@abhinashbihari2881
@abhinashbihari2881 4 года назад
We can use next_permutation(s.begin,s.end) to get next lexicographical greater string
@yashsalvi5043
@yashsalvi5043 2 года назад
How do you come up with such logics bro ? Legit 🐐
@arunkumarvaithiyanathan9808
@arunkumarvaithiyanathan9808 3 года назад
Please Explain Line 32: int firstSmallChar=charArray[endindex-1] why should we convert char to int ? Instead of do like Line 32: int firstSmallChar=endindex-1; Line 37: In 'if' condition (charArray[startindex]>charArray[firstSmallChar]) Thanks in Advance!!
@ashutoshaswal
@ashutoshaswal 4 года назад
From your reply on my solution! Thanks for helping me in optimizing the code!
@JavaAidTutorials
@JavaAidTutorials 4 года назад
most welcome..:)
@Mike-mw1fu
@Mike-mw1fu 4 года назад
Thank for helping me in optimizing code
@JavaAidTutorials
@JavaAidTutorials 4 года назад
Most welcome.
@navinchainani4721
@navinchainani4721 4 года назад
Bro u are best RU-vidr u are making future of ours keep doing bro
@JavaAidTutorials
@JavaAidTutorials 4 года назад
thanks. just trying to convey my knowledge in a best possible ways.
@satyasantosh3143
@satyasantosh3143 3 года назад
Very good explanation!
@JavaAidTutorials
@JavaAidTutorials 3 года назад
Glad it was helpful!
@Pr3kashSingh
@Pr3kashSingh 2 года назад
Thanks
@codeminatiinterviewcode6459
@codeminatiinterviewcode6459 4 года назад
I was doing the same thing but just using an extra string for return and hence HRank was giving Segmentation Fault... And I wasted 2 Hrs. in Detecting Error of Memory overload... I hope this helps... :)
@susritipal3747
@susritipal3747 4 года назад
Sir why you take endindex = n-1, extend- -, In the loop please explain
@reevarastogi6224
@reevarastogi6224 2 года назад
very nice explaination!!
@sagarock1012
@sagarock1012 4 года назад
Hey! I didn't get the question , how is "abcd" > "abdc" Thank you
@JavaAidTutorials
@JavaAidTutorials 4 года назад
you have to consider lexicographical order (alphabetical order).that's why abcd > abdc because abcd comes before abdc (if you look into dictionary)
@sandrakonotey4570
@sandrakonotey4570 3 года назад
@@JavaAidTutorials "abcd" < "abdc"(abcd is less than abdc) not "abcd" > "abdc"
@adarshjaiswal7334
@adarshjaiswal7334 4 года назад
I have started loving your vedios and parallelly the Hackerrank. But I was having a doubt here line37 :- Is it necessary to check charArray[startIndex]> firstSmallChar , bcz in the starting loop itself we have selected "d" which is smaller than all other so obviously value of charArray[startIndex] will be always greater than "d". Please let me understand if I misunderstood something.
@JavaAidTutorials
@JavaAidTutorials 4 года назад
Could you please mentioned the time as well , so that i can go and recall it.
@kratikavarshney1106
@kratikavarshney1106 5 лет назад
Thanks. Very clear
@JavaAidTutorials
@JavaAidTutorials 5 лет назад
thanks for you feedback @Kratika.
@rajasinghrajpoot8626
@rajasinghrajpoot8626 2 года назад
thank u very much brother..
@ankitkumar-ql4yh
@ankitkumar-ql4yh 3 года назад
hey i followed your video and did the same but still my half test cases are getting time out..i have commented my code in the discussion section in your comment thread ..please check it and tell me what im doing wrong
@rogercute2002
@rogercute2002 3 года назад
Why not "ecdfhi" is the answer?
@anuragsekhri2315
@anuragsekhri2315 4 года назад
well explained
@JavaAidTutorials
@JavaAidTutorials 4 года назад
thank you..:)
@tanmaysinghal8370
@tanmaysinghal8370 4 года назад
Bro please make the video solution for all the solution that is in there in your GitHub.
@JavaAidTutorials
@JavaAidTutorials 4 года назад
Sure, we are working on it. 👍
@abhishekshrivastav6193
@abhishekshrivastav6193 3 года назад
What is the complexity of this
@sterl1789
@sterl1789 5 лет назад
this solution is nlogn
@JavaAidTutorials
@JavaAidTutorials 5 лет назад
Hi Sterling Quinn, this is the catch here, it looks that its nlogn but it's not because sorting a string array will take O(nlogn) time but sorting a char array will take only O(n) time, you can apply counting sort for that.
@sterl1789
@sterl1789 5 лет назад
JAVAAID - Coding Interview Preparation oh cool that makes sense thank you!
@JavaAidTutorials
@JavaAidTutorials 5 лет назад
welcome. :) if you find this channel useful , please share with your friends.
@jhonhernandez9210
@jhonhernandez9210 6 месяцев назад
I couldn't understand much cause of tha english with indian accent
@AnkitKumar5
@AnkitKumar5 4 года назад
This is O(n^2) solution. Is there a better solution?
@JavaAidTutorials
@JavaAidTutorials 4 года назад
The above explained solution is having O(N) complexity 😊.
@kingnani1557
@kingnani1557 5 лет назад
Explain the code more clearly .. you're explaining the code very fast
@JavaAidTutorials
@JavaAidTutorials 5 лет назад
Thanks for your feedback @KING NANI , will try the same. Keep leaning , keep sharing..!!😊
@groot4957
@groot4957 2 года назад
Thanks
@linuxtubers7313
@linuxtubers7313 4 года назад
Thanks
@JavaAidTutorials
@JavaAidTutorials 4 года назад
Welcome
Далее
Minimum Distances HackerRank Solution
17:53
Просмотров 18 тыс.
How To Solve HackerRank Drawing Book Problem
11:00
Просмотров 17 тыс.
Premature Optimization
12:39
Просмотров 791 тыс.
Separate the Numbers HackerRank Solution
19:25
Просмотров 25 тыс.
Scammed selling my MacBook, almost
15:09
Просмотров 43 тыс.
How To Solve Counting Valleys HackerRank Problem
17:00
New Year Chaos HackerRank Solution
23:56
Просмотров 52 тыс.