mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-09-12 10:51:42 +08:00
批量更新数据
This commit is contained in:
@@ -2,13 +2,13 @@
|
||||
|
||||
<p>A <strong>triple booking</strong> happens when three events have some non-empty intersection (i.e., some moment is common to all the three events.).</p>
|
||||
|
||||
<p>The event can be represented as a pair of integers <code>start</code> and <code>end</code> that represents a booking on the half-open interval <code>[start, end)</code>, the range of real numbers <code>x</code> such that <code>start <= x < end</code>.</p>
|
||||
<p>The event can be represented as a pair of integers <code>startTime</code> and <code>endTime</code> that represents a booking on the half-open interval <code>[startTime, endTime)</code>, the range of real numbers <code>x</code> such that <code>startTime <= x < endTime</code>.</p>
|
||||
|
||||
<p>Implement the <code>MyCalendarTwo</code> class:</p>
|
||||
|
||||
<ul>
|
||||
<li><code>MyCalendarTwo()</code> Initializes the calendar object.</li>
|
||||
<li><code>boolean book(int start, int end)</code> Returns <code>true</code> if the event can be added to the calendar successfully without causing a <strong>triple booking</strong>. Otherwise, return <code>false</code> and do not add the event to the calendar.</li>
|
||||
<li><code>boolean book(int startTime, int endTime)</code> Returns <code>true</code> if the event can be added to the calendar successfully without causing a <strong>triple booking</strong>. Otherwise, return <code>false</code> and do not add the event to the calendar.</li>
|
||||
</ul>
|
||||
|
||||
<p> </p>
|
||||
|
Reference in New Issue
Block a user