July 25, 2022

On Sunday, 24 July 2022 at 15:49:51 UTC, Salih Dincer wrote:

>

On Sunday, 24 July 2022 at 15:11:45 UTC, Salih Dincer wrote:

>

...But you know this classic recurisive function:

The permut() function works with many types, for example char. Look at probability 40: 😀

void main() {
  int totalCount;
  ['a', 'd', 'g', 'l', 'n'].permut(totalCount);
  totalCount.writeln(" permutation found...");
} /* Output:

...
dagln: 25
dagnl: 26
dalgn: 27
dalng: 28
danlg: 29
dangl: 30
dgaln: 31
dganl: 32
dglan: 33
dglna: 34
dgnla: 35
dgnal: 36
dlgan: 37
dlgna: 38
dlagn: 39
dlang: 40
dlnag: 41
dlnga: 42
dngla: 43
dngal: 44
dnlga: 45
dnlag: 46
dnalg: 47
dnagl: 48
...
120 permutation found...

Process finished.

SDB@

not match by:

  1. the element is not repeat

  2. the element is position related

July 25, 2022

On Monday, 25 July 2022 at 04:23:16 UTC, test123 wrote:

>

not match by:

  1. the element is not repeat

  2. the element is position related

I got it now. So what good are such repetitive probabilities?

Thanks...

SDB@79

July 26, 2022

On Monday, 25 July 2022 at 21:43:37 UTC, Salih Dincer wrote:

>

On Monday, 25 July 2022 at 04:23:16 UTC, test123 wrote:

>

not match by:

  1. the element is not repeat

  2. the element is position related

I got it now. So what good are such repetitive probabilities?

Thanks...

SDB@79

just try a stupid game.

1 2
Next ›   Last »