1052. Grumpy Bookstore Owner | Sliding Window | Walmart Labs | EPAM Systems

Поділитися
Вставка
  • Опубліковано 25 гру 2024

КОМЕНТАРІ • 17

  • @mohit7717
    @mohit7717 6 місяців тому

    You clear question as I take 2 I miss consecutive minutes ... thanks Aryan

  • @shawtylikesfood
    @shawtylikesfood 6 місяців тому +1

    Did you buy the leetcode premium? Or are you using an extension?

  • @iankitveer
    @iankitveer 6 місяців тому

    What drawing tool is this ?

  • @prathamsharma4416
    @prathamsharma4416 6 місяців тому

    thanks broo

  • @codecraftV
    @codecraftV 6 місяців тому

    @Aryan Mittal Bro please answer my question can i say that this questions is similar to maximum sum sub array of length min , since we need maximum customers right? So , we have to maximize the sum , can i do it in that way

  • @codebreaker6578
    @codebreaker6578 6 місяців тому +5

    who else done it by themselves , without being grumpy 😂😂

  • @IK-xk7ex
    @IK-xk7ex 6 місяців тому +2

    I solved it by myself the same way, probably because there is no another way to solve it :)

  • @EngineeringWithBhavesh
    @EngineeringWithBhavesh 6 місяців тому +6

    am i only the one who was not able to do it on its own?

  • @harshal8781
    @harshal8781 6 місяців тому +2

    aaj company ke shirt dhone dale hai kya 🙃

  • @mohit7717
    @mohit7717 6 місяців тому

    I try to think the same problem using vector of pair but unable to do ...
    ```
    int maxSatisfied(vector& customers, vector& grumpy, int minutes) {
    vectorpr;
    for(int i=0;i

  • @ankitkumaryadav562
    @ankitkumaryadav562 6 місяців тому

    customers = [10,1,7]
    grumpy = [0,0,0]
    minutes = 2
    Output - 18
    Some body please explain me this how the output is 18
    It supposed to be "11"

    • @developer00007
      @developer00007 6 місяців тому +3

      Answer is 18 because the store owner is not grumpy throughout the minutes as you can see it's [0,0,0] hence there no need to use the minutes variable which is 2.

    • @ankitkumaryadav562
      @ankitkumaryadav562 6 місяців тому +1

      @@developer00007 Understand, I thought 0 means grumpy

    • @abinash1878
      @abinash1878 6 місяців тому

      Read the problem properly

    • @Sanjay-iy5zf
      @Sanjay-iy5zf 6 місяців тому

      Take time to read the problem cleary and become friend with it