nip.utils.string.random_string

Contents

nip.utils.string.random_string#

nip.utils.string.random_string(length: int, capitalise=True) str[source]#

Generate a random string of the given length.

Parameters:
  • length (int) – The length of the random string to generate.

  • capitalise (bool) – Whether to capitalise the first letter of the random string.

Returns:

random_string (str) – The generated random string.