Write code that will execute a list of functions with


Write code that will execute a list of functions with supplied parameters and report the observed runtime for each function run. Assume that the input file has a list of strings like so: Func1, Param1, Param2, Param3 Func2, Param1 You would need to execute Func1(Param1, Param2, Param3) and Func2(Param1) reporting the runtimes for each execution. You can assume that Func1 and Func2 are already defined. For your reference (if your python is a little rusty) -- if you need to look up the function that has been defined, you can do it as follows in python. First line looks up the function and the second line executes it with a parameter of 10. function1 = globals()['myFunction'] function1( 10 ) In order to make this work for more than one parameter, here is how you can do it. The first line looks up the function, second line converts the string into a tuple ('1, 2, 3' into (1, 2, 3)) and the third line allows you to pass multiple parameters to the function. Here we are assuming that myFunction2 takes three parameters. If you do not use eval, the input is a single string and not the three values that we need. If you do not use the * in the third line below, the tuple (1,2,3) would be treated as a single input and not three separate parameters. function2 = globals()['myFunction2']

Request for Solution File

Ask an Expert for Answer!!
Other Subject: Write code that will execute a list of functions with
Reference No:- TGS0602914

Expected delivery within 24 Hours