questions/python/page/15
Just import file without the '.py' extension. You can mark ...READ MORE
A TypeError can occur if the type ...READ MORE
Hi, @Rhydham, Try this: engine = pyttsx3.init('dummy') If you want ...READ MORE
Hey, @Natraj, This basically means that no response ...READ MORE
You need to implement your own __repr__ ...READ MORE
As mentioned in the error logs, try ...READ MORE
Appends object at the end. x = [1, ...READ MORE
Hi, @There, $ pip install gevent --pre $ pip ...READ MORE
Hello @kartik, For Python 2.6 and later and ...READ MORE
Hello @kartik, No there is not. You cannot ...READ MORE
Hi, @There, Regarding your query I would suggest ...READ MORE
Hello @kartik, You can import isfunction from the inspect module. >>> from inspect ...READ MORE
Hi, @Webinar, Are you getting any kind of ...READ MORE
This error is caused because we try ...READ MORE
I'm not sure that anything much could ...READ MORE
An abstract function cannot have functionality. You're basically ...READ MORE
It's because any iterable can be joined ...READ MORE
Hi@Aditya, It is working fine in my python ...READ MORE
It seems that the problem is not ...READ MORE
Hello @kartik, You can do: var = 1 if type(var) ...READ MORE
Hello @ nishit, Indentation means the space from margin to ...READ MORE
Use random.choice() import random foo = ['a', 'b', 'c', 'd', ...READ MORE
Python supports all the concept of "object ...READ MORE
I've found this snippet as an alternative ...READ MORE
Hello, @Hitesh, You can follow the below: print("List of ...READ MORE
from shutil import copyfile copyfile(src, dst) Copy the contents ...READ MORE
can any one suggest solution data['isLarge'] = data.size.map({'small' ...READ MORE
Hi, @Shrinidhi, Kindly share your code snippet with ...READ MORE
Hello @kartik, You can use dict.get() value = d.get(key) which will ...READ MORE
from shutil import copyfile copyfile(src, dst) Copy the ...READ MORE
Hello @S.P.D, First try to check your python ...READ MORE
A simple example using com types, converting ...READ MORE
Interfaces An interface is a contract: The person writing ...READ MORE
can you please help me on this. ...READ MORE
With Python older than 2.7/3.1, that's pretty ...READ MORE
os.remove() removes a file. os.rmdir() removes an empty directory. shutil.rmtree() deletes a ...READ MORE
Here is what you asked for: from functools ...READ MORE
Hey @Dipti email_s.append(email_1["email_address"]) This is the list on ...READ MORE
The default implementation is useless (it’s hard ...READ MORE
if You Want to convert int to ...READ MORE
#appriciate your helping email = input("enter your email ...READ MORE
in is the intended way to test for ...READ MORE
Hello @kartik, In your profile model provide related_name user ...READ MORE
The general pattern is str.split(search).join(replacement) This used to be ...READ MORE
You can use the + operator to combine them: listone ...READ MORE
Hello @kartik, If you still need to server ...READ MORE
There is no simple built-in string function ...READ MORE
I have the same issue and is ...READ MORE
Try hasattr(): if hasattr(a, 'property'): a.property The ...READ MORE
Hi, @Paradox, The error message IndentationError: expected an indented ...READ MORE
OR
At least 1 upper-case and 1 lower-case letter
Minimum 8 characters and Maximum 50 characters
Already have an account? Sign in.