An example of this can be found on my WSQ06, here’s the part of the code where i imported a module:<\/p>\n
import random #i<\/a> imported the module random that in this case it produces a random intenger from a certain parameter <\/p>\n value= random.randint(1,100) #What<\/a> this line does is that the variable value will become a random integer (random.randint) from 1 to 100 (1,100)<\/p>\n print(value)<\/p>\n This program will show a random value from 1 to 100.<\/p>\n —<\/p>\n Another example is:<\/p>\n import math #this<\/a> import the module math which has lots of functions that can be found here https:\/ pi=math.pi #pi<\/a> will take math.pi’s value which is equivalent to 3.1416…<\/p>\n print (pi)<\/p>\n This program will show:<\/p>\n 3.141592653589793<\/p>\n #mastery13<\/a><\/p>\n #TC1014<\/a><\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":" An example of this can be found on my WSQ06, here’s the part of the code where i imported a module:import random #i imported the module random that in this case it produces a random intenger from a certain parameter value= random.randint(… Continue reading