# 時計時間計算

時刻とは、通常コロン（hh:mm）でフォーマットされるある時点を指します。

### 時刻への時間の加算または減算

<pre><code><strong>now + 3 hours 15 minutes                | 6:26 pm
</strong>9:45 am - 15 hours 10 minutes | Yesterday at 6:35 pm
16:00 + 3 hours 12 minutes             | 7:12 pm
</code></pre>

{% hint style="info" %}
時刻の計算を行う際は、サマータイムが考慮されます。サマータイムが切り替わる日には、予期しない結果になる場合があります。
{% endhint %}

### 2つの時刻間の間隔の特定

```
7:30 to 20:45 | 3 hours 15 min
4pm to 3am    | 11 hours
```

### 時刻にマイナス（-）演算子を使用する場合の曖昧さ

残念ながら、マイナス演算子は時刻を扱う際に曖昧になることがあります。

私たちの多くは、これを使って**最初の時刻**から**2番目の時刻**（未来の時刻）までの**時間範囲**を示すために使用します。

`5pm - 9pm` （午後5時から午後9時まで）

しかし、私たちの中には、最初の時刻から2番目の時刻を**減算**として表現するためにこれを使用する人もいます。

`5pm - 3pm` （午後5時から午後3時を引く）

Soulverは、選択された特定の時刻に基づいて、あなたが何を意図しているかを解釈するよう最善を尽くします。

<pre><code>/// Get the amount of time between these two clock times today
5pm - 7pm         | 2 hours
<strong>5pm - 2pm | 2 hours
</strong>
// This is interpreted as 4 pm today back to 3am earlier this morning
4pm - 3am         | 13 hours

/// This is interpreted as 3am earlier this morning to 4pm today
3am - 4pm         | 13 hours
</code></pre>

最も予測可能な結果を得るには、[Finding the Interval between two clock times.](#finding-the-interval-between-two-clock-times) で説明されている「〜から」演算子を使用してください。


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://documentation.soulver.app/ja/rifarensu/time/clock-time-calculations.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
