Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

python json random number generator

import json 
from faker import Faker
import random
from random import randint
fake = Faker('en_US')
for _ in range(10):
    my_dict = {    'foo': randint(0, 100),    'bar': {'baz': fake.name(),       'poo': float(random.randrange(155, 389))/100   } }
    print(my_dict)
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #python #json #random #number #generator
ADD COMMENT
Topic
Name
6+8 =