</>OfferRetriever
DashboardDiscuss
NEW

Summer Sale

Limited Time Deal: Unlock all premium questions for over 30% off

$10.42$7.08

14

:

03

:

47

:

33

Get this deal
Back to Dashboard

Remove Consecutive for Balance

Medium

You are given a list of track lengths tracks and a positive integer k. Remove exactly k consecutive tracks from the list so that the sum of track lengths at even indices equals the sum at odd indices in the resulting list. Return the smallest valid starting index of the removed segment, or -1 if no such removal exists.

Indices are 0-based. The "even index sum" and "odd index sum" are computed on the resulting array after removal. ...

OfferRetriever

Master technical interviews with real questions from top companies. Build your confidence and career.

PRODUCT
PricingDashboardDiscussOfferRetriever vs LeetCode
LEGAL
POPULAR COMPANIES
GoogleMetaAmazonMicrosoftNetflixStripeUberTikTokBrowse all companies →

© 2026 Purple Business Holdings LLC. All rights reserved. See Terms of Service.