Skip to content

Tag: python-3.x

How to search and get rid of this character?

I have a lot of strings in a text file, and I noticed that one has this <200f> char. I want to find all entries that have this char and remove it. But in Vim I can’t find it by searching ‘<200f>’ using the search string ‘<200f>’. Probably it is one char not 6 in…

comparing numpy arrays with np.allclose()

I am new to Python. I cannot understand the behavior of the following code (I am trying to create a unit test for something): This code prints: Why when I print arrays their values are equal, but then I print their last items they are different? If the values are actually different, why is_equal2 is True? If …

File on Python (os.startfile) can’t be opend

I have a file in which search results (paths) are saved. I only want the very first result to be opend. I did this with: The print result is: O:/111/222/test_99.zip’ But the error is: FileNotFoundError: [WinError 2] system cannot find the file specified: O:/111/222/test_99.zip’ An addition: O: Is …