questions/python/page/31
import os from optparse import OptionParser, Option class MyOption ...READ MORE
Usually all I/Os are buffered, meaning they ...READ MORE
If you want to use the same ...READ MORE
You can try this @Mahesh: lst = [ ...READ MORE
This worked for me: from Tkinter import * from ...READ MORE
Hey, this code worked for me: image_path=os.path.abspath('.\\folder1\\subfolder2\file1.jpg') driver.find_element_by_id("Id of ...READ MORE
x = int(input("Enter any number \n")) print("The factors ...READ MORE
Please use this code. if len(sys.argv) == 2: first_log ...READ MORE
You have initialized driver only once and ...READ MORE
The reason for this error is that ...READ MORE
The optimal CutOff value is the point ...READ MORE
Use the following piece of code: x1=datetime.timedelta(days=3000, seconds=0, ...READ MORE
Hey, I think this should do what ...READ MORE
There is a syntax error. Change the ...READ MORE
Here's the code: check = input("Enter the character: ...READ MORE
There is a button "btn_closeWin_and_reinit" in the ...READ MORE
Not sure which dataset you are using. ...READ MORE
Refer to this code: import pandas as pd col_name=['Name', ...READ MORE
I have two triangles that has to ...READ MORE
You can use the pandas library for this which ...READ MORE
Inline if-else expression must always contain the else ...READ MORE
Hey, You can use np.greater(b, f) np.greater_equal(b, f) np.less(b, f) np.less_equal(b, ...READ MORE
To clear a canvas, use the delete method. This ensures ...READ MORE
yes, you can use "os.rename" for that. ...READ MORE
Hey @Starsarwar You have two different codes, they ...READ MORE
Sorted!!!! just found the solution, 1 - apparently ...READ MORE
You can use sleep as below. import time print(" ...READ MORE
when to use which? Use list.sort when you ...READ MORE
df = pd.DataFrame({'month': [1, 4, 7, 10], 'year': ...READ MORE
Catch the error and handle it: try: ...READ MORE
<a class="quickreports btn btn3d tbbtn" href="javascript:" style="position:static" ...READ MORE
OOP reflects the real world behavior of ...READ MORE
I have written below code and its ...READ MORE
There are different places you can add ...READ MORE
Hi @Ahmed. Here's a sample code that ...READ MORE
def Binary_search (array , element): ...READ MORE
If you're on Windows, you'll notice that ...READ MORE
Name value DR_CNDAOFSZAPZP_GPFS_VOL.0 139264 DR_CNDAOFSZAPZP_GPFS_VOL.1 15657 DR_CNDAOFSZAPZP_GPFS_VOL.0 139264 DR_CNDAOFSZAPZP_GPFS_VOL.1 156579 DR_CNDAOFSZAPZP_GPFS_VOL.2 156579 DR_CNDAOFSZAPZP_GPFS_VOL.3 ...READ MORE
You can specify the class you want ...READ MORE
TRY THIS #Nomalisation for i in names: print(i) ...READ MORE
Basically, my code runs a turtle and ...READ MORE
Tuples are a Unchanging sequence of values, ...READ MORE
As per the documentation, The pprint module provides a capability ...READ MORE
You can do it like this: df=pd.DataFrame(columns=["Name","Old","Ne ...READ MORE
I am supposed to use python 2.7 ...READ MORE
Here is the code for it. da=[ {"age":34, "id":1, "name":"Tony", "salary":1400, "dept_no":[10,20], "Cntct":{"Phone":[1234567890,9876543210], "state":"NY", ...READ MORE
The key is to start the thread ...READ MORE
Here's the logic. You have to add ...READ MORE
If you want to access outer class ...READ MORE
Hey @Anvit, you can use something like ...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.