Velikost videa: 1280 X 720853 X 480640 X 360
Zobrazit ovladače přehrávání
Automatické přehrávání
Přehrát
your logic was right and explanation was also good , but there were a little wrong in your codehere my c++ code with your logic //class Solution {public: bool find132pattern(vector& nums) { if(nums.size()=0;i--){ if(mini >nums[i])return true; while(!st.empty() and st.top()
Best visual diargram for this question.
Thanks mate!
You have not traversed the array from last to first .
👎 for not traversing array from left to right while explaining
Does not work. Please dry run for array containing 132
your logic was right and explanation was also good , but there were a little wrong in your code
here my c++ code with your logic
//class Solution {
public:
bool find132pattern(vector& nums) {
if(nums.size()=0;i--){
if(mini >nums[i])return true;
while(!st.empty() and st.top()
Best visual diargram for this question.
Thanks mate!
You have not traversed the array from last to first .
👎 for not traversing array from left to right while explaining
Does not work. Please dry run for array containing 132