Orray || Codeforces Round 827 Div4 Problem G

𝐑𝐞𝐠𝐢𝐬𝐭𝐞𝐫 𝐟𝐨𝐫 𝐍𝐞𝐰𝐭𝐨𝐧 𝐒𝐜𝐡𝐨𝐨𝐥 𝐂𝐨𝐝𝐢𝐧𝐠 𝐂𝐨𝐦𝐩𝐞𝐭𝐢𝐭𝐢𝐨𝐧:
𝐋𝐢𝐧𝐤: bit.ly/3c3DYvl
-----------------------------------------------------------------------------------
📌𝐃𝐢𝐬𝐜𝐨𝐫𝐝: bit.ly/youtube-discord
📌𝐋𝐢𝐧𝐤𝐞𝐝𝐈𝐧: / newto. .
📌𝐈𝐧𝐬𝐭𝐚𝐠𝐫𝐚𝐦: / newtonschoo. .
📌𝐅𝐚𝐜𝐞𝐛𝐨𝐨𝐤: / newtonschool.co
------- 𝐀𝐛𝐨𝐮𝐭 𝐍𝐞𝐰𝐭𝐨𝐧 𝐒𝐜𝐡𝐨𝐨𝐥 -------
🔵NEWTON SCHOOL is an online Edtech company providing the highest-rated FULL STACK DEVELOPMENT PROGRAM for professionals, graduates, and women.
🌕NEWTON SCHOOL is your gateway to a high-paying tech career in 6 months with Zero fees till placement, transforming you into a rockstar full-stack developer earning 5-40 Lakh per annum salary. Newton School’s students are already working in more than 150+ top companies of India including Zomato, Unacademy, Deloitte, Nutanix, etc.
🔵To watch more videos on programming, Data Structures, Android Development, Data Science, C++, Java, React, subscribe to our channel.
- - - - - - - - - - - - - -
If you're reading this far down, hello, you look nice today :)
Orray || Codeforces Round 827 Div4 Problem G
#NewtonSchool #NS #Fullstack #FSD #Datascience #MS #Postgrad #webdeveloper #programming #programmer #programmers #developer #coder #programmingmemes #coders #coding #frontenddeveloper #backenddeveloper #html #softwaredeveloper #hacking #python

Пікірлер: 33

  • @parthabhowmik4747
    @parthabhowmik4747 Жыл бұрын

    That was a crystal clear explanation, thanks bhaiya 😊

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    Thanks Parth

  • @arijitdey8419
    @arijitdey8419 Жыл бұрын

    great explanation as always...thanks a lot for the solution

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    Thanks Arijit as always.

  • @rajmittal5394
    @rajmittal5394 Жыл бұрын

    I figured that we need 30 elements only but the relation B[i] = B[i-1]|A[i] not came in my mind Thanks a lot

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    Thanks Raj :)

  • @susrandomguy
    @susrandomguy Жыл бұрын

    thanks. nice explanation as always.

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    Thanks Subham

  • @yousefsameh4622
    @yousefsameh4622 Жыл бұрын

    What a creative solution 👏🏼

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    Thanks Yousef

  • @nguyentrungnguyen8355
    @nguyentrungnguyen8355 Жыл бұрын

    tks for your solution

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

  • @rasecbadguy5600
    @rasecbadguy5600 Жыл бұрын

    Good explanation help me a lot

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    Thanks Rasec

  • @sahilanand30
    @sahilanand30 Жыл бұрын

    Nicely explained :)

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    Thanks ;)

  • @yourbestie4138
    @yourbestie4138 Жыл бұрын

    Great

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    🍻

  • @eugenesidelnyk4600
    @eugenesidelnyk4600 Жыл бұрын

    I would really like to know how do you reason about the problem, and how do you actually find the solution. Because as for me, it is easy to understand the solution, but it's hard to find it. From your video I pointed out these steps: - describe what's given - describe what's necessary to achieve - describe naive solution - observe the naive solution and find data patterns - think up optimization - describe the final solution - write it down. But how do you solve the issues when you first see them? Could you give some advice?

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    Reading and analysing a problem gives an idea in which direction you need to think. Like if you have GCD and such think in terms of Prime Factors, and if you bitwise operations think in terms of Binary. Next step is to carefully observe the samples and try to dry run some test cases to get some kind of observation. This comes with practice and is the most important part. Rest is just implementation which is not that hard.

  • @Surya045_
    @Surya045_ Жыл бұрын

    Why cant we directly sort in reverse order and print it ?Is there any case where this fails ?

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    say in binary form numbers are 11010, 1001, 100. Then optimal answer is 11010 -> 100 -> 1001 and you can clearly see, its not reverse sorted.

  • @Surya045_

    @Surya045_

    Жыл бұрын

    @@competitivecoding-newtonsc9601 thx got it

  • @DuongNguyen-cu3bb
    @DuongNguyen-cu3bb Жыл бұрын

    can you do F problem

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    will try to

  • @midhileshmomidi3120
    @midhileshmomidi3120 Жыл бұрын

    Why are taking min(n, 30) ?

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    How can you choose 30 elements if your n = 20?

  • @rikchik7709
    @rikchik7709 Жыл бұрын

    what would the expected rating be for this?

  • @kasiruyamagata7716

    @kasiruyamagata7716

    Жыл бұрын

    1700

  • @competitivecoding-newtonsc9601

    @competitivecoding-newtonsc9601

    Жыл бұрын

    nah more like 1500

  • @rikchik7709

    @rikchik7709

    Жыл бұрын

    @@competitivecoding-newtonsc9601 yeah 1700 is way too high