title: create instance of a class using function in python
body: <p>I want to define a function that takes in name, type and list of parameters(of class) as input and creates an instance of class of given type and given name with specified parameters. and Save it in a dictionary with name as key Value How to do it?
  I have tried using</p>
  
  <pre><code>return globals()['name']=globals()['type](globals("".join(list_of_parameter)))
  </code></pre>
  
  <p>but it didn't work I even tried to use <code>eval()</code></p>
  
  <p>instead of <code>globals()</code> but it doesn't work either.</p>
  
  <p>(name and type are strings list_of_parameters is a list of strings where each string is a variable or object) </p>