Irfan Baqui
Irfan Baqui
  • 24
  • 1 288 776
How to be a Successful Software Developer: Open Source Contributions
Brought to you by Interview Accelerator at www.interviewaccelerator.com
In this video, you will learn how you can become a successful software developer by making open source contributions.
Open source contributions can greatly enhance your career as a software engineer, but it's hard to get started with them. I'll tell you the benefits of contributing to open source software and how to easily get started with making your first open source contribution.
zhlédnutí: 8 414

Video

N-Queens - Coding Interview Question (Backtracking Algorithm)
zhlédnutí 46KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com ! For weekly coding practice, check out irfanbaqui.com/coding-interview-prep And hear about the upcoming course on Data Structures and Algorithms for Coding Interviews: eepurl.com/dhWjSH In this video, I solve the N-Queens problem with a backtracking algorithm. The problem is - how do you place n queens...
Largest Rectangle in a Histogram - Coding Interview Question
zhlédnutí 104KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com ! *Largest Rectangle Under A Histogram* Today's problem is about finding the largest rectangle within a histogram. We'll explore a linear time solution. I encourage you to try and solve this problem before looking at the video. Then post your solution below. I give you two options toward the end of the ...
Largest Square of 1's in A Matrix (Dynamic Programming)
zhlédnutí 142KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com Dynamic Programming - A ridiculously simple explanation. In the video, I show you how we can turn a complex coding interview question into a simple one through dynamic programming. The problem is also known as 'Maximum Sub Square Matrix' - Given a matrix of 0s and 1s, find the biggest sub-square matrix ...
Coding Interview Question with Graphs: Depth First Search
zhlédnutí 36KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com Coding interview with undirected graph and DFS (depth first search). For weekly coding practice, check out irfanbaqui.com/coding-interview-prep
Find the intersection between arrays: Coding Interview Question
zhlédnutí 56KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com It's crucial to know how to operate on multiple arrays at the same time. Coding questions involving array intersection get asked at big companies like Google, Facebook and Microsoft all the time. And they're also frequently asked at startups. In this video, I'll first show you how not to solve this ques...
Validate Parenthesis In a String (Coding interview problem) - Whiteboard Thursday
zhlédnutí 26KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com Today's problem is about validating parentheses. All good code editors need a way to tell you whether your code has the right set of parentheses. We will implement an algorithm that does just that. Also look out for next week's problem that I mention in the video. Try it out yourself and subscribe to ge...
Google Coding Interview Question and Answer: Find Cycle in Array - Whiteboard Thursday
zhlédnutí 125KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com Next week's problem: How do you determine whether a string has balanced parenthesis? Try the problem yourself and subscribe for the solution coming out next week!
Coding Interview: Reverse Array in Place - Whiteboard Thursday
zhlédnutí 20KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com Here is the problem I'll cover in next week's Whiteboard Thursday: You're given an array of integers where each element contains the index to the next element. Determine if the array has a cycle. Try it out yourself and leave your answers in the comments below. And subscribe to get notified of the solut...
Longest Consecutive Sequence In An Array - Coding Interview on Whiteboard Thursday
zhlédnutí 67KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com
Fibonacci Series: #1 Most Common Coding Interview Question - Whiteboard Thursday
zhlédnutí 79KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com Today I cover the #1 most asked coding question in interviews. This problem throws off a lot of folks, so I go through both a recursive and an iterative implementation. Please like and subscribe, and I'll see you next week!
Facebook Interview: K Most Frequent Elements - Whiteboard Thursday
zhlédnutí 64KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com As always, don't forget to like, subscribe and share! I'll see you with a new video next week.
How To Make Money While Still Learning To Code
zhlédnutí 16KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com
Array Manipulation in Place: Coding Interview Question in Whiteboard Thursday
zhlédnutí 25KPřed 6 lety
Check out the detailed data structures and algorithms course at www.interviewaccelerator.com As always, don't forget to like, subscribe and share! I'll see you with a new video next week.
Coding Interview: King And Queen On A Chessboard - Whiteboard Wednesday
zhlédnutí 17KPřed 6 lety
Coding Interview: King And Queen On A Chessboard - Whiteboard Wednesday
Google Interview Question: Implement A Queue With A Stack - Whiteboard Wednesday
zhlédnutí 55KPřed 6 lety
Google Interview Question: Implement A Queue With A Stack - Whiteboard Wednesday
How To Get 3600% More Interviews - Step-By-Step Guide For Software Engineers
zhlédnutí 7KPřed 6 lety
How To Get 3600% More Interviews - Step-By-Step Guide For Software Engineers
Amazon Coding Interview - Overlapping Rectangles - Whiteboard Wednesday
zhlédnutí 273KPřed 6 lety
Amazon Coding Interview - Overlapping Rectangles - Whiteboard Wednesday
Coding Interview with Binary Trees, Queues and Breadth First Search - Whiteboard Wednesday
zhlédnutí 47KPřed 6 lety
Coding Interview with Binary Trees, Queues and Breadth First Search - Whiteboard Wednesday
Whiteboard Interview with Arrays and Hash Maps - Whiteboard Wednesday
zhlédnutí 57KPřed 6 lety
Whiteboard Interview with Arrays and Hash Maps - Whiteboard Wednesday
How Twitter Scaled Its Engineeering Systems To Support Millions Of Tweets
zhlédnutí 4,1KPřed 6 lety
How Twitter Scaled Its Engineeering Systems To Support Millions Of Tweets
Introduction to Express Gateway
zhlédnutí 2,7KPřed 7 lety
Introduction to Express Gateway
What is an Api Gateway
zhlédnutí 9KPřed 7 lety
What is an Api Gateway
React Router v4 : Everything You Need to Know (with real examples)
zhlédnutí 3,3KPřed 7 lety
React Router v4 : Everything You Need to Know (with real examples)

Komentáře

  • @sakshamchhimwal322
    @sakshamchhimwal322 Před 19 dny

    Clear Concise Awesome!!!!

  • @iftak01
    @iftak01 Před 2 měsíci

    Thanks 🙏 😊

  • @ShubhamSharma-rm9ry
    @ShubhamSharma-rm9ry Před 6 měsíci

    what about this : [-2,1,-1,-2,-2] , this contains cycle at 1, -1 but leetcode says it does not, and expects a false for (int i = 0; i < nums.Length; i++) { int pointer = i; if (nums[pointer] == 0) continue; int prev = pointer; int steps = 0; Console.WriteLine($"i :{i}"); while (true) { Console.WriteLine($"steps : {steps}, prev : {prev}, pointer : {pointer}"); if (steps > 1 && nums[pointer] == 0) return true; int modNo = nums[pointer] < 0 ? nums.Length - Math.Abs(nums[pointer]) % nums.Length : nums[pointer]; int nextPos = (pointer + modNo) % nums.Length; Console.WriteLine($"nextPos : {nextPos}"); nums[pointer] = 0; prev = pointer; pointer = nextPos; steps++; if (prev == pointer) break; } } return false;

  • @user-si2sx5oq1e
    @user-si2sx5oq1e Před 6 měsíci

    wahesh khaye l irfan!

  • @vasudev9496
    @vasudev9496 Před 8 měsíci

    Are you learning or Teaching?

  • @jimitrupani8998
    @jimitrupani8998 Před 10 měsíci

    Good

  • @stanislawpalka9015
    @stanislawpalka9015 Před rokem

    Non-optimal. Second part (Bucket) should be on heap.

  • @Lord_Garmad0n
    @Lord_Garmad0n Před rokem

    merci le sang ggrace a toi j'ai eu un sur vinfgt

  • @sakshishah6059
    @sakshishah6059 Před rokem

    One more correction is that in else it will be like (stack.isEmpty()?i:i-1-s.peek())

  • @sakshishah6059
    @sakshishah6059 Před rokem

    Too good explanation but just a correction it will be if(stack.isEmpty() || hist[stack.peek()<=hist[I]) Thanks for the video it was very much helpful

  • @93hothead
    @93hothead Před rokem

    Jesus jobs nowadays with such a tough interview and your job is not even secure

  • @rahulcapoor
    @rahulcapoor Před 2 lety

    bhai kya bol raha hai

  • @maniakapps
    @maniakapps Před 2 lety

    if (RectA.X1 < RectB.X2 && RectA.X2 > RectB.X1 && RectA.Y1 > RectB.Y2 && RectA.Y2 < RectB.Y1)

  • @cihadp
    @cihadp Před 2 lety

    function areaOfOverlap([[ax1, ay1], [ax2, ay2]], [[bx1, by1], [bx2, by2]]) { const len = ([a1, b1], [a2, b2]) => Math.min(a1, b1) - Math.max(a2, b2) const ox = len([ax2, bx2], [ax1, bx1]) if (0 > ox) return 0 const oy = len([ay2, by2], [ay1, by1]) if (0 > oy) return 0 return ox * oy }

  • @AlexN2022
    @AlexN2022 Před 2 lety

    if we start at index 0 this is so easy that 1) I would not expect this at a Google interview and 2) there's an easier solution: if we can make N steps without going out of bounds, there's a loop. Same big-O complexity, but about twice faster in reality. If however a loop can start at any index, then it becomes interesting

  • @IrvineMesa
    @IrvineMesa Před 2 lety

    Hi Irfan .. I wanted to ask can I get a testimonial for my CV from the owner of the repository after I have done my CONTRIBUTIONS

  • @jamesvanvuren
    @jamesvanvuren Před 2 lety

    The solution for this could use a modified B+ tree where the interior nodes store the separators between the sets and the leaf nodes only store sequence start value + sequence length for each set. There would be one leaf node per consecutive sequence. The driver function would just build the B+ tree, and keep track of the largest sequence as it did so.

  • @zionsiton3690
    @zionsiton3690 Před 2 lety

    Great video and approach to answering the question for a coding interview by the way. One thing I would change based on your solution would be to start the iterators at 1 instead of zero. Not only would that save iterations (as you don't need to change the cloned values when i or j are zero, but it also removes the need to check if i or j are zero. Again, great video

  • @arunkumarm6004
    @arunkumarm6004 Před 2 lety

    I need answer for this question Given an array of Given an array of N integers where each number a[x] indicates a stack of cubical bricks of height a[x] Essentially the array represents N stacks of bricks. The goal is to determine the largest nxn matrix (square matrix ) embedded in this array of stack Input format: First line indicates the size of the integer array say N Each of the next N lines represent the height of the stack at index x where 12,+x<=N Constraints 1<=N<10^4 0<=x<10^4 Output Value of n where nxn matrix is the largest one embedded in the stacks.

  • @fawadhassan9036
    @fawadhassan9036 Před 2 lety

    When are new videos coming

  • @yunuskocatas3879
    @yunuskocatas3879 Před 2 lety

    main() {

  • @yunuskocatas3879
    @yunuskocatas3879 Před 2 lety

    this is my way

  • @alisheheryar1770
    @alisheheryar1770 Před 2 lety

    Sometimes I got zoned out. Nice effort but still room for improvement.

  • @hailin716
    @hailin716 Před 2 lety

    Bad. Most of programmers can’t even solve it with recursive, why everyone directly jump to DP without more detail in recursive way.

  • @pranavkumarsoni7518
    @pranavkumarsoni7518 Před 2 lety

    very great explanation.

  • @wasabi_san
    @wasabi_san Před 3 lety

    In what language can a method return either boolean or int?

  • @prithwishdasgupta4508

    If we mark the index that the current index is pointing to by making that no. Negative ...so we can check if the no. Is already negative then it's visited that means it has cycle. So time complexity will be O(N) and space complexity will be O(1) as we are using the given array for marking.

  • @chandrakantkumarchoudhary1144

    this concept is not about which is better its about how well you understand stack and recursion'

  • @zemfus
    @zemfus Před 3 lety

    Спасибо большое, дорогой учитель Ирфан

  • @z08840
    @z08840 Před 3 lety

    so, if stack is a million elements deep we are just using a million deep call STACK.... rrrrrrrrright.... well, thank you, I'm leaving - have no interest to work here :P

  • @dannydjx
    @dannydjx Před 3 lety

    Dude, this man is going serious with the look and feel. He's even using blue shirts for FB videos.

  • @vahiagyat
    @vahiagyat Před 3 lety

    Maybe I missed it but isn't it a big assumption to consider rectangles edges will be parallel to the x, y-axis? or rather two rectangles will be parallel.

    • @likwidmocean
      @likwidmocean Před rokem

      It's addressed early in the video that the rectangles will be composed of lines oriented parallel to the xy axis. You're right in that it is a big assumption, but if you think about it, it's implicit in the input format. "Sloped rectangles" embedded in a plane need to describe at least 3 vertices, so the two edges required to form a 90° corner (a vertex) are represented. The corner becomes the local origin, use pythagoras to get the edge lengths, multiply for area. For "non-sloped rectangles" you just need 2 opposing vertices to find the edges required to calculate area. This is because rectangles by definition are composed of 4 congruent interior angles of 90°, and 2 sets of 2 congruent edges. It'd occasionally useful to consider a square as a special case rectangle. If it were a rhombus, all 4 vertices are required to find area. So the question in my opinion to ask is not, "are there sloped rectangles?" but rather "is the input format stable or variable? Will all rectangles be described with two vertices?". From that you should be able to describe the system's capacity for rectangles to the interviewer, demonstrating an awareness of how a rule, in this case the geometric identity of a rectangle, is used to omit unnecessary data from a model without losing any information about the object the model describes.

  • @adityabhandari6688
    @adityabhandari6688 Před 3 lety

    watched this video twice and it worked for me

  • @tdsora
    @tdsora Před 3 lety

    You spent the first 8 minutes saying you were going to do top down DP, then suddenly you started doing bottom up DP. If this was supposed to simulate a real interview, that was be pretty obvious you knew the solution already.

  • @_ityadi
    @_ityadi Před 3 lety

    Time complexity for the solution would be O(n!) that is Big-O of n factorial

  • @_ityadi
    @_ityadi Před 3 lety

    Thanks for showing we can cheat using a recursion call stack instead. I would have assumed this can not be done since I thought using recursion is basically using a stack and discarded this solution. Next time I would not assume things in the interview, rather just ask the interviewers if I can do it or not.

  • @AkshayKumar-ck1yg
    @AkshayKumar-ck1yg Před 3 lety

    when Input= [1,2,3,4,5,0,9,8,0,1,2,3,6,0,5,4,7] ...?

  • @BrentSnider
    @BrentSnider Před 3 lety

    Great video

  • @chikinfrydsteak
    @chikinfrydsteak Před 3 lety

    Very helpful! Thanks so much

  • @sumekagarwal8229
    @sumekagarwal8229 Před 3 lety

    Do we have a case where one rectangle is parallel to x axis and the other not parallel (both in quadrant 1)?

  • @jamezjaz
    @jamezjaz Před 3 lety

    Insightful! Thanks for sharing

  • @debdutsaha4316
    @debdutsaha4316 Před 3 lety

    I am also thinking the same

  • @AlbinoCordeiroJunior
    @AlbinoCordeiroJunior Před 3 lety

    Great video, as always

  • @vaibhavsachdeva2261
    @vaibhavsachdeva2261 Před 3 lety

    very nice sir well explained!

  • @66IOU3
    @66IOU3 Před 3 lety

    I was expecting to see a different implementation because of the disconnection of E and F. Interesting to see its the same as a typical DFS.

  • @stephanbranczyk8306
    @stephanbranczyk8306 Před 3 lety

    Just a small note, do not completely rely on Grammarly. Grammarly occasionally makes mistakes. So if you're not 100% sure it's a mistake, do not submit a PR for it.

  • @davidjames1684
    @davidjames1684 Před 3 lety

    I would go about this differently... Since we know the input matrix is 4 rows and 5 columns, the largest square of 1s there can be is 4x4, so the only place that can be is at the upper left corner or 1 element to the right of that. As soon as we scan across the top row, we see a 0, and realize a 4x4 of 1s cannot be present. We repeat this logic with 3x3 and find it and then we are done. No need to fuss with squares of size 2x2 in this example because we are checking largest (4x4) to smallest (1x1) and stopping when we find one (in this case stopping at 3x3). More specifics about the algorithm at the 3x3 check step would be scan across until we find 3 ones in a row (literally), go back to that "home" position (the leftmost element), and scan down to see if there are 3 ones in a column. If so, now we have a 3x3 "outline" so check the remaining elements inside that (only 4 more elements to check). If all are ones, we are done. Actually an improvement of this algorithm can be to first count up the # of 1s. Since we only have 14, we know that a 4x4 square of 1s is not possible, so immediately start looking for 3x3s since there are at least 9 1s. There are likely many more algorithms that will solve this too. Probably dozens.

  • @TheSkeef79
    @TheSkeef79 Před 3 lety

    Actually, you can solve this problem in O(log(n)) time using matrices and binary exponentiation ( I don't know us it necessary in interviews)

  • @samanrajaei8129
    @samanrajaei8129 Před 3 lety

    XOR would be the simplest as suggested by a few others. If I was doing your solution, I'd add the new 'unvisited' element to a stack, pop the element when I see it next and whichever elements stays in the stack at the end is your guy.

  • @ankitajain3243
    @ankitajain3243 Před 3 lety

    What is a cycle?