<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def rand_ascii_str(length):
 """Generates a random string of specified length, composed of ascii letters and digits. Args: length: The number of characters in the string. Returns: The random string generated. """

    letters = [random.choice(ascii_letters_and_digits) for _ in range(length)]
    return ''.join(letters)