Count and Say | Made Super Easy | Google | Explanation | Live Coding

  Рет қаралды 15,201

codestorywithMIK

codestorywithMIK

Күн бұрын

Пікірлер: 44
@tilakbhujade4438
@tilakbhujade4438 10 ай бұрын
Very nice explanation. Pura ka pura logic samajh gaya. Apke logic se code maine khud hi solve kar diya. Thanks Sir!!! (That superbike sound in the BG tho...)
@codestorywithMIK
@codestorywithMIK 10 ай бұрын
😇🙌🙏 Thanks a lot
@aakarsh987
@aakarsh987 9 ай бұрын
Damn I saw so many explanations but couldn't understand anyone, you explained in a magical way, it was so amazing, thank you!!
@Anikashukla1808
@Anikashukla1808 3 ай бұрын
whats the time and space complexity?
@MounikaEMB
@MounikaEMB Жыл бұрын
Just started strings playlist.😊 As per question its hard to understand but after your explanation it is easy for me to understand... Thank you for making such a great videos for us🙏
@codestorywithMIK
@codestorywithMIK Жыл бұрын
So glad it helped Thank you 😇🙏
@csengineer8819
@csengineer8819 26 күн бұрын
sir pheli baar hindi dekhi coding ke question ... pura 1-12th ka hindi medium school yaad agya
@ArjunSaxena-wl3qs
@ArjunSaxena-wl3qs 9 ай бұрын
Amazing ! . . . . . . class Solution: def countAndSay(self, n: int) -> str: if n == 1 : return '1' def helper(n) : if n == 1 : return '1' say = helper(n - 1) # processing i,j = 0,1 res = '' count = 1 while j < len(say) : if say[i] == say[j] : count += 1 else: res += str(count) + say[i] count = 1 i = j j += 1 res += str(count) + say[i] return res return helper(n)
@vineetjadhav1785
@vineetjadhav1785 2 ай бұрын
Very Great Explaination ❤❤👋👋
@souravjoshi2293
@souravjoshi2293 2 жыл бұрын
Dude this became so easy. Thanks
@sp_9467
@sp_9467 3 ай бұрын
Very nice handwriting
@akshatprakash126
@akshatprakash126 5 ай бұрын
great explanation! hidden gem of a video
@knight-z1x
@knight-z1x 4 ай бұрын
bdiya smjha ya apne
@_PRANAYMATE
@_PRANAYMATE 3 ай бұрын
Understood and code it on my own thanks bro
@AjitKumar-jr7jo
@AjitKumar-jr7jo Жыл бұрын
Today i sit in a OA of a company ,and it is the 1st question out of 3 , i could not understand this question, i totally got panicked and won't able to solve a single question.;)
@codestorywithMIK
@codestorywithMIK Жыл бұрын
Thank you for sharing but it’s ok, keep practising and soon you will be able to crack interviews. Would you mind sharing which company’s OA was it ?
@AjitKumar-jr7jo
@AjitKumar-jr7jo Жыл бұрын
@@codestorywithMIK it is on-campus company name is zessta.
@DevOpskagyaan
@DevOpskagyaan 10 ай бұрын
Such a fine explanation man. 🙌
@leo71648
@leo71648 7 ай бұрын
One of the best explanation and as you said explanation on Leetcode is Pathetic, Keep it up
@jagadeeshp1163
@jagadeeshp1163 Жыл бұрын
class Solution: def rec(self,n): if n==1: return "1" temp=self.rec(n-1) count=1 ch=temp[0] ns="" for i in range(1,len(temp)): if temp[i]==ch: count+=1 elif ch!=temp[i]: ns+=str(count)+ch ch=temp[i] count=1 ns+=str(count)+ch return ns def countAndSay(self, n: int) -> str: return self.rec(n) Done✅
@sayantanpoddar5428
@sayantanpoddar5428 11 ай бұрын
please came up with " Remove Outermost Parentheses" solution
@RohitGupta-xf3zp
@RohitGupta-xf3zp Жыл бұрын
nice bhaiya tgra logic build and inituiton
@codestorywithMIK
@codestorywithMIK Жыл бұрын
Thank you so much ❤️
@kiranshelar2961
@kiranshelar2961 Жыл бұрын
Excellent explanation!
@codestorywithMIK
@codestorywithMIK Жыл бұрын
Glad it was helpful! ❤️❤️
@Rajnish-pu8mj
@Rajnish-pu8mj 5 ай бұрын
great teacher
@pranavmaiya4386
@pranavmaiya4386 Ай бұрын
bro but this goes off to exponential complexity (2^n) , if interviewer expects us to optimize it then ?
@_Deepak__Verma
@_Deepak__Verma 8 ай бұрын
why length is say.length() instead of i
@ShivamGupta-cx3hy
@ShivamGupta-cx3hy 2 жыл бұрын
Thank you sir 😊
@codestorywithMIK
@codestorywithMIK 2 жыл бұрын
Appreciate your comments ❤️
@pranavmaiya4386
@pranavmaiya4386 Ай бұрын
what about the follow up question ?
@mohdafzal4017
@mohdafzal4017 7 ай бұрын
Thanks alot.. feedback- you need to level up your thumbnail game
@santoshbhatnagar2155
@santoshbhatnagar2155 6 ай бұрын
what is the time complexity for this question?
@TechVIP
@TechVIP Жыл бұрын
What is the time complexity for this?
@mgnfy-view
@mgnfy-view 11 ай бұрын
I coded the same solution with typescript but got a low score on time and space complexity.
@jeethora586
@jeethora586 5 ай бұрын
please explain time ans space complexity
@B_Patidar88
@B_Patidar88 Ай бұрын
Bhaiya java me solve karvao pls
@PakIslam2012
@PakIslam2012 Жыл бұрын
why recursion, why not a for loop?
@codestorywithMIK
@codestorywithMIK Жыл бұрын
You can loop this too i guess. Recursion seems more easy to me . So i choose Recursion mostly
@beinginnit
@beinginnit Жыл бұрын
Paypal asked this question in it's offcampus interview😅😅
@allmovies2473
@allmovies2473 4 ай бұрын
Noise cancellation wala mic use✅Please✅
@codestorywithMIK
@codestorywithMIK 4 ай бұрын
Sure ❤️
@mayankkumar6628
@mayankkumar6628 5 ай бұрын
bhai tera explaination poora dekhne se pehle hi karliya if n ==1: return str(1) else : temp = str(self.countAndSay(n-1)) prev = temp[0] length=1 ans="" for i in range(1,(len(temp))): if prev == temp[i] : length+=1 else : ans =ans+str(length) ans +=prev prev = temp[i] length =1 ans +=str(length) ans +=prev return ans
@carefree_ladka
@carefree_ladka 22 күн бұрын
var countAndSay = function (n) { if (n === 1) return '1'; return countAndSay(n - 1) .match(/1+|2+|3+/g) .reduce((acc, nums) => acc += `${nums.length}${nums[0]}`, '') }; much simpler
What😳Software Engineers Dont Work from Home?🔴
0:43
Curious Freaks
Рет қаралды 21 М.
Don't underestimate anyone
00:47
奇軒Tricking
Рет қаралды 21 МЛН
快乐总是短暂的!😂 #搞笑夫妻 #爱美食爱生活 #搞笑达人
00:14
朱大帅and依美姐
Рет қаралды 13 МЛН
40 Blind75 | Insert Interval
21:02
ak tiwari
Рет қаралды 4
C Programming Tutorial for Beginners
3:46:13
freeCodeCamp.org
Рет қаралды 14 МЛН
Machine Learning for Everybody - Full Course
3:53:53
freeCodeCamp.org
Рет қаралды 8 МЛН
Next Permutation | Google | Microsoft | Amazon | Leetcode 31
25:45
codestorywithMIK
Рет қаралды 16 М.
Pointers in C / C++ [Full Course]
3:47:23
freeCodeCamp.org
Рет қаралды 4,5 МЛН