(something) in python is only needed if you need to change the order of
precedence or if you need to split something across 2 or more lines.
Otherwise, it has no meaning and it is extraneous.

On Tue, Oct 19, 2021 at 9:42 AM <[email protected]> wrote:

> See the following testing in IPython shell:
>
> In [6]: import numpy as np
>
> In [7]: a = np.array([1], dtype=(bool))
>
> In [8]: b = np.array([1], dtype=bool)
>
> In [9]: a
> Out[9]: array([ True])
>
> In [10]: b
> Out[10]: array([ True])
>
> It seems that dtype=(bool) and dtype=bool are both correct usages. If so,
> which is preferable?
>
> Regards,
> HZ
> _______________________________________________
> NumPy-Discussion mailing list -- [email protected]
> To unsubscribe send an email to [email protected]
> https://mail.python.org/mailman3/lists/numpy-discussion.python.org/
> Member address: [email protected]
>
_______________________________________________
NumPy-Discussion mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/numpy-discussion.python.org/
Member address: [email protected]

Reply via email to