Ad
  • Custom User Avatar

    thanks man

  • Custom User Avatar

    C translation (author gone)

  • Custom User Avatar

    Oh so I checked and it seems that my edits are not the reason for the error. But it needs to be fixed anyway, I will take care of this.

  • Custom User Avatar

    Oh that's because I removed one character from the alphabet and didnt adjust the sampling function. I will fix this.

    Sorry for the problem.

  • Custom User Avatar

    (OP is talking about JavaScript)
    I can confirm the issue, there is an off-by-one error in the RNG:

    let characters = "abcdefghijklmnopqrstuvwqyzABCDEFGHIJKLAMNOPQRSTUVWXYZ0123456789!@#$%^&*()-_+={}[]|\:;?/>.<,)";
    // characters.length === 91
    ...
    random += characters[Math.round(Math.random() * 91)]
    // worst-case scenario: random += characters[91] i.e. undefined
    
  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    your code does not use the Python sum, it defines that name as a variable to hold an integer

    but FYI that's a bad coding practice because you overwrite the built-in function of that name

  • Custom User Avatar

    I started to learn how code a few days ago. I just tryed searching in other websites and i found it.
    Never expeted chatgpt goed help me in this moment, this mf teach me what is the function "sum"