generate functionTue, 07 Mar 2023

print a random number with 12 decimal places in the range from 0 to n where n is a fractional number.

import random def print_rand(n): return random.random() * n print_rand(1.8)

Questions about programming?Chat with your personal AI assistant