[Solved] Given the head of a sorted linked list, delete all duplicates such that each element appears only once. Return the linked list sorted as well.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] Given the head of a sorted linked list, delete all nodes that have duplicate numbers, leaving only distinct numbers from the original list. Return the linked list sorted as well.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] Given an integer array nums sorted in non-decreasing order, remove some duplicates in-place such that each unique element appears at most twice. The relative order of the elements should be kept the same.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] Given an array nums with n objects colored red, white, or blue, sort them in-place so that objects of the same color are adjacent, with the colors in the order red, white, and blue. We will use the integers 0, 1, and 2 to represent the color red, white, and blue, respectively.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] Given a string path, which is an absolute path (starting with a slash ‘/’) to a file or directory in a Unix-style file system, convert it to the simplified canonical path.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] You are climbing a staircase. It takes n steps to reach the top. Each time you can either climb 1 or 2 steps. In how many distinct ways can you climb to the top?Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] Given a non-negative integer x, compute and return the square root of x. Since the return type is an integer, the decimal digits are truncated, and only the integer part of the result is returned.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] Given two binary strings a and b, return their sum as a binary string.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] You are given a large integer represented as an integer array digits, where each digits[i] is the ith digit of the integer. The digits are ordered from most significant to least significant in left-to-right order. The large integer does not contain any leading 0’s. Increment the large integer by one and return the resulting array of digits.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] Given a m x n grid filled with non-negative numbers, find a path from top left to bottom right, which minimizes the sum of all numbers along its path.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] You are given an m x n integer array grid. There is a robot initially located at the top-left corner (i.e., grid[0][0]). The robot tries to move to the bottom-right corner (i.e., grid[m-1][n-1]). The robot can only move either down or right at any point in time. An obstacle and space are marked as 1 or 0 respectively in grid. A path that the robot takes cannot include any square that is an obstacle.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] There is a robot on an m x n grid. The robot is initially located at the top-left corner (i.e., grid[0][0]). The robot tries to move to the bottom-right corner (i.e., grid[m – 1][n – 1]). The robot can only move either down or right at any point in time. Given the two integers m and n, return the number of possible unique paths that the robot can take to reach the bottom-right corner.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] Given the head of a linked list, rotate the list to the right by k places.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] Given a string s consisting of words and spaces, return the length of the last word in the string. A word is a maximal substring consisting of non-space characters only.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] You are given an integer array nums. You are initially positioned at the array’s first index, and each element in the array represents your maximum jump length at that position. Return true if you can reach the last index, or false otherwise.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] Given an integer array nums, find the contiguous subarray (containing at least one number) which has the largest sum and return its sum.Leetcode SolutionsAbhishek SharmaSeptember 8, 2022
[Solved] Implement pow(x, n), which calculates x raised to the power n (i.e., xn).Leetcode SolutionsAbhishek SharmaSeptember 7, 2022
[Solved] Given an array of strings strs, group the anagrams together. You can return the answer in any order. An Anagram is a word or phrase formed by rearranging the letters of a different word or phrase, typically using all the original letters exactly once.Leetcode SolutionsAbhishek SharmaSeptember 7, 2022
[Solved] You are given an n x n 2D matrix representing an image, rotate the image by 90 degrees (clockwise). You have to rotate the image in-place, which means you have to modify the input 2D matrix directly. DO NOT allocate another 2D matrix and do the rotation.Leetcode SolutionsAbhishek SharmaSeptember 7, 2022
[Solved] Given a collection of numbers, nums, that might contain duplicates, return all possible unique permutations in any order.Leetcode SolutionsAbhishek SharmaSeptember 7, 2022