Live Mock Interview | Real Time Technical Round

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

GeeksforGeeks

GeeksforGeeks

Күн бұрын

Пікірлер: 19
@GeeksforGeeksVideos
@GeeksforGeeksVideos 3 жыл бұрын
In the question of finding peak element, due to lack of time we were not able to see its implementation , whereas the algorithm (traversing entire array or using binary search(moving left when mid element is smaller than to its adjacent left element or moving right when mid element is smaller than to its adjacent right element) and checking peak element) proposed in video is correct and works perfectly fine atleast when all the elements are distinct in input array, provided the entire algorithm along with basic checks is implemented correctly, for one of the inputs(there could be many) {3 3 4 4 4 4} where values are duplicate in input array,if we go with the algorithm proposed in video there (will/may) be some issues, as we need to check for equality cases also while doing comparisons, so we need to modify the definition of peak element as the following : Correction : Let the input array "arr" be of length "n" and we have a variable "i" which is iterating on "arr" , so if (i > 0 and i < n) then, arr[i] is a peak element if (arr[i] >= arr[i-1] and arr[i] >= arr[i+1]) if (i == 0) then arr[i] is a peak element if (arr[i] >= arr[i+1]) if (i == n-1) then arr[i] is a peak element if (arr[i] >= arr[i-1]) ,please comment if you have any queries/doubts.
@enigma368
@enigma368 3 жыл бұрын
1st problem - next smaller nearest to right 2nd problem - find peak element from array
@mukeshojha9318
@mukeshojha9318 3 жыл бұрын
First use pen and paper for thinking and dry run because I am beginning and i only know about all data structure and algorithm but not solve many problems and when I got new questions and try to solve on paper, it's like magic like after 20-30 minutes of thinking I am able to know that which DSA I should use to solve it. It works very well.
@Praveen-zq8ox
@Praveen-zq8ox 3 жыл бұрын
Yes great approach
@prateekjain7623
@prateekjain7623 3 жыл бұрын
How to praticipate in interview??
@srikanthsangani7121
@srikanthsangani7121 3 жыл бұрын
It's seems he has already solved 1st question earlier I guess bcuz coming up with O(n) solution not even thinking for a minute is highly not possible.
@venugopalreddy8596
@venugopalreddy8596 3 жыл бұрын
That's a basic question while doing stacks. So anyone can think of the solution in a matter of seconds if he's a DSA guy.
@devakash2
@devakash2 3 жыл бұрын
can't we just return minimum so far array in second question where he is asking about right to left. if minimum so far = self: return -1 else return minimum so far
@sarcasmtube69
@sarcasmtube69 3 жыл бұрын
see exp: 4 3 2 now for this acc to u min so far from right will be 2 and acc fo ur logic ans will be 2 2 -1 but actual ans is 3 2 -1 u want next smaller not the smallest on right..
@codeitclean1882
@codeitclean1882 3 жыл бұрын
great..was really helpful
@high-oncode7576
@high-oncode7576 3 жыл бұрын
Can we give interviews with beard and mustache
@BalajiVishnubhotla
@BalajiVishnubhotla 3 жыл бұрын
Next smaller to 7 is 5 not 1. Here 1 is the smallest element next to 7 but not smaller..
@Fcukrey
@Fcukrey 3 жыл бұрын
The problem states next smaller i.e. it wants first element encountered on right which is smaller than current element
@avishekdutta2951
@avishekdutta2951 3 жыл бұрын
Too easy
@hiteshusingh8571
@hiteshusingh8571 3 жыл бұрын
Very good interview
@shaikakber4717
@shaikakber4717 3 жыл бұрын
Thank you
@mrgenius9396
@mrgenius9396 3 жыл бұрын
OMG wht a Great Guy 🥵🥵🥵🥵🥵🥵Mar gaya🤣
@ShivamTiwari-ci2qg
@ShivamTiwari-ci2qg 3 жыл бұрын
This person has good coding skills but less problem solving skill.
@jdragon8184
@jdragon8184 3 жыл бұрын
i have wasted so much time on vs code , it sucks
Live Mock Interview | Product & Service-Based Companies
1:02:22
GeeksforGeeks
Рет қаралды 10 М.
If people acted like cats 🙀😹 LeoNata family #shorts
00:22
LeoNata Family
Рет қаралды 45 МЛН
When Rosé has a fake Fun Bot music box 😁
00:23
BigSchool
Рет қаралды 6 МЛН
Live Mock Interview | Technical Round - Product Based Companies
1:01:16
Israel Has The Right To Defend Itself | Stand-up Comedy by Daniel Fernandes
15:07
Webinar | My Interview Experience at Infosys
25:23
GeeksforGeeks
Рет қаралды 6 М.
System Design Interview: Design Uber w/ a Ex-Meta Staff Engineer
1:03:05
Hello Interview - SWE Interview Preparation
Рет қаралды 127 М.
Live Mock Interview #1
34:57
GeeksforGeeks
Рет қаралды 19 М.
How To Pass Technical Interviews When You Suck At LeetCode
14:32
the TRUTH about C++ (is it worth your time?)
3:17
Low Level
Рет қаралды 785 М.
System Design Mock Interview: Design TikTok ft. Google TPM
33:11