John is working on a Machine Learning project where he has some specific requirements, one of them being that the Numpy and Pandas library installed in the system needs to be of a specific version.
You need to help John find the Numpy and Pandas version installed.
check_ver
instance
instance
Taking you to the next exercise in seconds...
Want to create exercises like this yourself? Click here.
No hints are availble for this assesment
Note - Having trouble with the assessment engine? Follow the steps listed here
Please login to comment
12 Comments
Hi the code I wrote is correct but the test case seems outdated. The np version as per my notebook is '1.19.5' but the test case is checking for '1.16.4'. Please check that.
Hi Janhavi,
Thanks for bringing this to our notice. We have fixed it.
Upvote Sharedef check_ver(instance):
ver = instance.__version__
return ver
import numpy as np
check_ver(np)
import pandas as pd
check_ver(pd)
what is the error here
Upvote Sharedef check_ver(instance):
return instance.__version__
print(check_ver(pd))
print(check_ver(np))
When I submit the above code I am getting error in test case :type(check_ver)
Upvote ShareThis comment has been removed.
check_ver is function so it will print function only.
Upvote ShareMy code is also printing 'function' when I check type(check _ver). Then also am not able to submit the code.
Upvote SharePlease check the instructions. We are supposed to return version and not type
Upvote ShareSir you please check my code. My function-check_version is returning version. But when I submit code it is giving error in test case 'type(check_version)' is not returning function. So I have checked type(check_version) in my code which is also returning function.
Please follow these steps if you are facing any challenges with the assessment engine https://discuss.cloudxlab.com/t/im-having-problem-with-assessment-engine-how-should-i-fix/3734
Upvote ShareThe code is pretty simple and I have matched it with solution provided by cloudaxlab also. There is no issues related to assessment engine also.
This type of problem is occuring in some other questions also ( in this module- Mains solutions). I think results of assessment exam also had little issues because of these problems.
Upvote ShareHi,
Could you please elaborate on the prblem and attach the screenshot if you are still facing an issue?
Thanks.
Upvote Share