@@ -213,10 +213,10 @@ A :class:`timedelta` object represents a duration, the difference between two
213
213
Only *days *, *seconds * and *microseconds * are stored internally.
214
214
Arguments are converted to those units:
215
215
216
- * A * millisecond * is converted to 1000 * microseconds * .
217
- * A * minute * is converted to 60 * seconds * .
218
- * An * hour * is converted to 3600 * seconds * .
219
- * A * week * is converted to 7 * days * .
216
+ * A millisecond is converted to 1000 microseconds.
217
+ * A minute is converted to 60 seconds.
218
+ * An hour is converted to 3600 seconds.
219
+ * A week is converted to 7 days.
220
220
221
221
and days, seconds and microseconds are then normalized so that the
222
222
representation is unique, with
@@ -285,21 +285,15 @@ Note that, because of normalization, ``timedelta.max > -timedelta.min`` is true.
285
285
286
286
Instance attributes (read-only):
287
287
288
-
289
- .. attribute :: timedelta.days
290
-
291
- Between ``-999999999 `` and ``999999999 `` inclusive.
292
-
293
-
294
- .. attribute :: timedelta.seconds
295
-
296
- Between ``0 `` and ``86399 `` inclusive.
297
-
298
-
299
- .. attribute :: timedelta.microseconds
300
-
301
- Between ``0 `` and ``999999 `` inclusive.
302
-
288
+ +------------------+--------------------------------------------+
289
+ | Attribute | Value |
290
+ +==================+============================================+
291
+ | ``days `` | Between -999999999 and 999999999 inclusive |
292
+ +------------------+--------------------------------------------+
293
+ | ``seconds `` | Between 0 and 86399 inclusive |
294
+ +------------------+--------------------------------------------+
295
+ | ``microseconds `` | Between 0 and 999999 inclusive |
296
+ +------------------+--------------------------------------------+
303
297
304
298
Supported operations:
305
299
@@ -375,7 +369,7 @@ Notes:
375
369
This is exact and cannot overflow.
376
370
377
371
(3)
378
- Division by `` 0 `` raises :exc: `ZeroDivisionError `.
372
+ Division by zero raises :exc: `ZeroDivisionError `.
379
373
380
374
(4)
381
375
``-timedelta.max `` is not representable as a :class: `timedelta ` object.
@@ -1221,7 +1215,7 @@ Supported operations:
1221
1215
object *t * such that ``datetime2 + t == datetime1 ``. No time zone adjustments
1222
1216
are done in this case.
1223
1217
1224
- If both are aware and have different :attr: `~.datetime.tzinfo ` attributes, ``a - b `` acts
1218
+ If both are aware and have different :attr: `~.datetime.tzinfo ` attributes, ``a- b `` acts
1225
1219
as if *a * and *b * were first converted to naive UTC datetimes. The
1226
1220
result is ``(a.replace(tzinfo=None) - a.utcoffset()) - (b.replace(tzinfo=None)
1227
1221
- b.utcoffset()) `` except that the implementation never overflows.
0 commit comments