Leetcode 66. Plus One
Vložit
- čas přidán 26. 07. 2024
- Leetcode 66. Plus One
leetcode.com/problems/plus-one/
My contact details
Instagram :- / frazmohammad
Connect with me on LinkedIn :- / mohammad-f-bb4886157
Telegram Group t.me/LeadCoding
FREE INTERVIEW PREPARATION SERIES • Free Interview Prepara...
You can practice for coding interview from here
Leetcode Hard :- • Hard
Leetcode Medium :- • Medium
Leetcode Easy :- • Easy
I am Mohammad Fraz , a final year Engineer at DTU and I create content for Coding and technical interviews for FAANG. I explain the intuition to solve Data Structure and Algorithm Questions from leetcode and other platforms. I also cover interview experiences for FAANG and other tech giants. You will also find lectures on the frequently asked interview questions.
I am happy a person like you providing us too much cheaper and simplest solution of many questions, which are too much easy for understand.....
THANKYOU FRAZ BHAIYA...🥰
You are a genius it just blows my mind with every video explaination i watch on your channel ,hats off
Too short and crisp code 🔥
It is 100 % faster than all other codes on leetcode
the way you added 1 at the beginning is impressive
Great explanation
Thanks 😊
best explaination ever love from Assam
amazing approach
Good explanation ❤. What astonishes me is "D.size()".
Thankyou bhaiya for this session
great
too short, too good and too crisp!! thank you so much
,,,,☺️
how to create new vector can anyone give me that solution
❤️❤️🙏
please share a java code for this question
---------------The Java Code --------------
class Solution {
public int[] plusOne(int[] digits) {
for(int i=digits.length-1;i>=0;i--){
if(digits[i] ==9){
digits[i]=0;
}else{
digits[i]++;
return digits;
}
}
int[] res = new int[digits.length+1];
res[0]=1;
return res;
}
}