Adding more folders to chapter 2
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
# myrandomv2.py with default and custom random functions
|
||||
import random
|
||||
|
||||
#random = __import__('random')
|
||||
|
||||
#random = importlib.import_module('random')
|
||||
print (globals())
|
||||
|
||||
def random_1d():
|
||||
"""This function get a random number between 0 and 9"""
|
||||
return random.randint(0,9)
|
||||
|
||||
def random_2d():
|
||||
"""This function get a random number between 10 and 99"""
|
||||
return random.randint(10,99)
|
||||
Reference in New Issue
Block a user