Тёмный

Streak Saved | 2073. Time Needed to Buy Tickets | leetcode daily challenge | DSA | Hindi | shashwat 

shashCode
Подписаться 16 тыс.
Просмотров 1,3 тыс.
50% 1

Problem Name:
2073. Time Needed to Buy Tickets
Problem Statement:
There are n people in a line queuing to buy tickets, where the 0th person is at the front of the line and the (n - 1)th person is at the back of the line.
You are given a 0-indexed integer array tickets of length n where the number of tickets that the ith person would like to buy is tickets[i].
Each person takes exactly 1 second to buy a ticket. A person can only buy 1 ticket at a time and has to go back to the end of the line (which happens instantaneously) in order to buy more tickets. If a person does not have any tickets left to buy, the person will leave the line.
Return the time taken for the person at position k (0-indexed) to finish buying tickets.
Problem link:
leetcode.com/problems/time-ne...
Java Plus DSA Placement Course Playlist:
• Java and DSA Course Pl...
Java Plus DSA Sheet:
docs.google.com/spreadsheets/...
Notes:
github.com/Tiwarishashwat/Jav...
Telegram Link:
shashwattiwari.page.link/tele...
Ultimate Recursion Series Playlist:
• Recursion and Backtrac...
Instagram Handle: (@shashwat_tiwari_st)
shashwattiwari.page.link/shas...
Samsung Interview Experience:
• I cracked Samsung | SR...
Company Tags:
Facebook | Amazon | Microsoft | Netflix | Google | LinkedIn | Pega Systems | VMware | Adobe | Samsung
Timestamp:
0:00 - Introduction
#ShashwatTiwari #coding​​ #problemsolving​

Опубликовано:

 

8 апр 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 7   
@adityakadam3895
@adityakadam3895 3 месяца назад
We were waiting for you shash sir for today's solution and your approach towards the problem 😊❤
@user-oi5ls4rs5g
@user-oi5ls4rs5g 3 месяца назад
placement sir k channel se hoga java walo.......placement baba ki jai ho
@mr.nishantawasthi4402
@mr.nishantawasthi4402 3 месяца назад
Sir problem subha hi upload kar diya kariye please kyo ki subha sahi rehta hai
@PradeepKumarIIITD
@PradeepKumarIIITD 3 месяца назад
bhai time lgta h.. solve --> video --> edit --> upload...
@Inspire_with_SM
@Inspire_with_SM 3 месяца назад
bhaiya mey aaj ka problem afternoon mey hi submit kardiya easy tha
@dibbodas4116
@dibbodas4116 3 месяца назад
sir can you also share the thinking process how do you approach a problem
@chinubunny9974
@chinubunny9974 3 месяца назад
Bro give me some tip. I don't able to solve any question own by own . Please guide
Далее
Чистка пляжа с золотом
00:49
Просмотров 276 тыс.
Я КУПИЛ САМЫЙ МОЩНЫЙ МОТОЦИКЛ!
59:15
Ouch.. 🤕
00:30
Просмотров 6 млн
My Brain after 569 Leetcode Problems
7:50
Просмотров 2,5 млн