filmov
tv
Find First and Last Position of Element in Sorted Array | #shorts |Javascript #leetcode
Показать описание
“Find First and Last Position of Element in Sorted Array Leetcode Solution,” we will discuss the solution to a leetcode problem. In the given problem we are given an array. We are also given a target element. Elements in the array are sequenced in increasing order.
We need to find the first and last position of the target element in the sorted array.
If the target element is not present then return [-1,-1].
Example 1:
Input: nums = [5, 7, 7, 8, 8, 10], target = 8
Output: [3, 4]
Required knowledge
Basic JavaScript programming, If else, While loop
Disclaimer:
All videos are for educational purpose and use them wisely. Any video may have a slight mistake, please take decisions based on your research. This video is not forcing anything on you.
Video Course will be 100% free and will be released on YouTube. The playlist will be updated with new DS Based tutorial videos every week. The plan is to cover all the important concepts of DS & Algorithms.
Put your comments and share your experience with us if you like this video Also if you have some suggestions then please suggest them in the comment box.
Javascript
udemy javascript
javascript course
ES6
Thank's For Watching This Video
Like Share Subscribe