> On 26 Jul 2022, at 16:07, Cecil Westerhof via Python-list
> wrote:
>
> I need to get a random integer. At first I tried it with:
>from secrets import randbelow
>index = randbelow(len(to_try))
>
> This works perfectly, but it took some time. So I thought I try:
>from random imp
On Wed, 27 Jul 2022 at 09:28, Dennis Lee Bieber wrote:
>
> On Tue, 26 Jul 2022 16:38:38 +0200, Cecil Westerhof
> declaimed the following:
>
> >I need to get a random integer. At first I tried it with:
> >from secrets import randbelow
> >index = randbelow(len(to_try))
> >
> >This works per
On Tue, 26 Jul 2022 23:47:59 +0200, Cecil Westerhof
declaimed the following:
>The new code:
>from random import SystemRandom
>system_random = SystemRandom()
>index = system_random.randint(0, len(to_try) - 1)
>
>The first two statements are executed once.
>The last statement I thin
On Tue, 26 Jul 2022 16:38:38 +0200, Cecil Westerhof
declaimed the following:
>I need to get a random integer. At first I tried it with:
>from secrets import randbelow
>index = randbelow(len(to_try))
>
>This works perfectly, but it took some time. So I thought I try:
>from random impo
On Wed, 27 Jul 2022 at 08:18, Cecil Westerhof via Python-list
wrote:
>
> Chris Angelico writes:
>
> > On Wed, 27 Jul 2022 at 06:06, Cecil Westerhof via Python-list
> > wrote:
> >>
> >> Chris Angelico writes:
> >>
> >> > On Wed, 27 Jul 2022 at 01:06, Cecil Westerhof via Python-list
> >> > wrote
Chris Angelico writes:
> On Wed, 27 Jul 2022 at 06:06, Cecil Westerhof via Python-list
> wrote:
>>
>> Chris Angelico writes:
>>
>> > On Wed, 27 Jul 2022 at 01:06, Cecil Westerhof via Python-list
>> > wrote:
>> >>
>> >> I need to get a random integer. At first I tried it with:
>> >> from se
On Wed, 27 Jul 2022 at 06:06, Cecil Westerhof via Python-list
wrote:
>
> Chris Angelico writes:
>
> > On Wed, 27 Jul 2022 at 01:06, Cecil Westerhof via Python-list
> > wrote:
> >>
> >> I need to get a random integer. At first I tried it with:
> >> from secrets import randbelow
> >> index
Chris Angelico writes:
> On Wed, 27 Jul 2022 at 01:06, Cecil Westerhof via Python-list
> wrote:
>>
>> I need to get a random integer. At first I tried it with:
>> from secrets import randbelow
>> index = randbelow(len(to_try))
>>
>> This works perfectly, but it took some time. So I thoug
On 27/07/2022 06.24, KK CHN wrote:
> List ,
>
> I have come across a difficulty to understand the code in this file. I am
> unable to understand exactly what the code snippet is doing here.
>
> https://raw.githubusercontent.com/CODARcode/MDTrAnal/master/lib/codar/oas/MDTrSampler.py
>
> I am new
List ,
I have come across a difficulty to understand the code in this file. I am
unable to understand exactly what the code snippet is doing here.
https://raw.githubusercontent.com/CODARcode/MDTrAnal/master/lib/codar/oas/MDTrSampler.py
I am new to this type of scientific computing code snippets
On Wed, 27 Jul 2022 at 01:06, Cecil Westerhof via Python-list
wrote:
>
> I need to get a random integer. At first I tried it with:
> from secrets import randbelow
> index = randbelow(len(to_try))
>
> This works perfectly, but it took some time. So I thought I try:
> from random import
Absolutely. The task (“generate a random number”) is ill-defined.
Want a fast random number? Use 552015933 (I just retrieved it from random.org).
Want a true random number, use random.org API. (https://api.random.org/pricing).
Something in between, follow approaches Stefan suggests.
—
Gerard
I need to get a random integer. At first I tried it with:
from secrets import randbelow
index = randbelow(len(to_try))
This works perfectly, but it took some time. So I thought I try:
from random import SystemRandom
index = SystemRandom().randint(0, len(to_try) - 1)
A first indic
Hello,
I am not sure if I looked into the correct sources. I was looking in
"PEP 609 – Python Packaging Authority (PyPA) Governance" [1] and the
"PyPA specifications" [2].
My question in short: Is there an official document (e.g. a PEP) about a
recommended layout for project folders.
Looki
Here we are. The universe. The vastness of spacetime. At the edge. The last
frontier. The last beta*(conditions apply) for Python 3.11.
We have defied the powerful gods of release blockers and we have won by
using the required amount of ruse and subterfuge.
https://www.python.org/downloads/releas
Op 25/07/2022 om 16:43 schreef Dennis Lee Bieber:
On Mon, 25 Jul 2022 10:39:46 +0200, Antoon Pardon
declaimed the following:
Yes it is, but it doesn't answer my question: How do I create a package
in which a file is built at install time.
I just want to build a configuration file that will amo
16 matches
Mail list logo