Good day. I have code that converts results data frame to CSV. I have another code that in samae script that allows  to name the csv file.When program runs user is asked to name the csv file and its generated.Question is how can i have a mechanism in the case that user enters the same name of an existing file stored in pycharm file that prompts the user that file name exists already and enter another one.  I have tried to use if statements that check if strings is equal to existing file without success.  filename=str(input('Insert file name')) results=pandas.dataframe() results.to_csv("%s.csv"%filename)   I expect the code to check when use inputs name to check in directory if file name already exists
How do I check whether a file exists or not, without using the  statement?
The suffix -phobia means fear of, often irrational fear of.  For example, according to Wikipedia:       or ophiophobia is a particular type of specific phobia,   the abnormal fear of snakes.   Is there a suffix attachable to ophidio- which would describe a person who is not afraid of snakes, except for, say, a coiled rattler encountered on a trail, but who dislikes them and would not willingly share space with one?  Similarly, an  (don't click here if you are at all arachnophobic) is someone who loves spiders.  Is there a suffix for someone who likes spiders but does not love them?  These are Greek suffixes, and the Greeks, theoretically, were in favor of moderation.  So, are there suffixes in use in English, derivable from Greek or not, for moderate like and moderate dislike?    Edit to explain why the question:  "Is there a suffix for loathing" does not answer my question.  My question is NOT about fear and/or loathing.  My question is about moderate dislike (and moderate like).  I can watch a snake cross my driveway with interest, but would not want it in the house or lounging on my patio.   A person who loathed snakes would not be able to admire the smooth motion of the snake as it glided over the rough gravel and disappeared into the woods.  Loathe is very different from moderate dislike; Phobia is very different from caution. A switch that is only ON if the reference voltage is matched -+ 0.1 volts Im a beginnerish will electronic and im looking for a switch that is only ON if the reference voltage is matched -+ 0.25 volts. So if i have a reference of 2.7v to match and i feed the switch a 2.75v the switch would be ON. But if i feed it  2.5v or 2.85v the switch would is OFF.   This might be a simple google search, but i am lacking the correct terminology. Is there a direct download link with a raw data dump of Stack Overflow? (not a torrent) I would like to create a local MySQL copy of Stack Overflow for academic purposes (school project). As far as I know, the database dump of the  database is available only in an XML format that I will have to convert to SQL on my own with some tool.  Most of direct download links I found were broken (404). The only non-torrent source that I have found and that is still alive is  but the latest Stack&nbsp;Overflow dump there is from October 2009, content of which looks like this:    Where could I find a direct download link with the Stack&nbsp;Overflow dump?    Note: I am not able to use torrents due to network policies, yet for the completeness of this question, here's the link that might help someone:    Other related questions / links that haven't helped me:     ~ all links there give 404  ~ from September '09 with another broken link  ~ from about a year ago with a clearbits.net link  ~ also not working anymore Can the problem of unification of Quantum Mechanics and General Relativity be converted into a pure Mathematical problem? I mean to say, can you make someone understand the problem who only knows Mathematics, even if a Physics description is absent? I mean, describing the problem with unification using pure Mathematical formulation.  Can we make the problem seem as if it has nothing to do with the real world and describe it only as a problem of mathematics? Does reviewing queues have any gains for me as a Stack Overflow user? Configure proxy for APT? Create bash file to open minecraft launcher I use this command in the terminal to run the minecraft launcher with java 8:  /home/max/Java/jre1.8.0_25/bin/java -jar Minecraft.jar   I included the full java path because I installed it on /home as a normal user and i want to include it.   That command works, it opens the launcher with Java 8 but I want to make a bash file so I don't have to open the terminal. And, most important, I don't want the terminal to remain open when I click play in the Minecraft launcher and the game starts.  Now if i close manually the terminal when the game have started, the game is closed too. Determine if an element has a CSS class with jQuery I'm working with jQuery and looking to see if there is an easy way to determine if the element has a specific CSS class associated with it.  I have the id of the element, and the CSS class that I'm looking for.  I just need to be able to, in an if statement, do a comparison based on the existence of that class on the element. Is a sentence always grammatically incorrect if it has no verb? Is the following grammatically correct? My friend says the second sentence is grammatically incorrect, but couldn't explain why.     I have always been fascinated by statistics. The different ways in   which you could look at data and infer knowledge from it. Is it legal to develop a game using D&D rules? For a while now I've been thinking about trying my hand at creating a game similar in spirit and execution to Baldur's Gate, Icewind Dale and offshoots. I'd rather not face the full bulk of work in implementing my own RPG system - I'd like to use D&amp;D rules.  Now, reading about the subject it seems there is something called "The License" which allows a company to brand a game as D&amp;D. This license seems to be exclusive, and let's just say I don't have the money to buy it :p.  Is it still legal for me to implement and release such a game? Commercially or open-source? I'm not sure exactly which edition would fit the best, but since Baldur's Gate is based of 2nd edition, could I go ahead an implement that?  in short: what are the issues concerning licensing and publishing when it comes to D&amp;D?  Also: Didn't see any similar question... When to use \par and when \\, \newline, or blank lines Can't access pre populated SQLite database using PhoneGap/Cordova in Android How to find/grep what is between string1 and string2? I am trying to extract a value from a long string that may change over time. So for example the string could look something like this  ....../filename-1.9.0.3.tar.gz"&lt;....   And what I want to extract is the value between filename- and .tar.gz, essentially the file version (1.9.0.3 in this case). The reason I need to do it this way is because I may later run the command and the value will be 1.9.0.6 or 2.0.0.2 or something entirely different.  How can I do this? I'm currently only using grep, but I wouldn't mind using other utilities such as sed or awk or cut or whatever. To be perfectly clear, I need to extract only the file version part of the string, since it is very long (on both sides) everything else needs to be cut out somehow. Why does Calculate button remain gray in Group Stats Plugin for QGIS? In my case I failed to use  plugin (2.0.30) with QGIS 2.14.11 and 2.18.3 on windows64.  Tested on several datasets: points, polygons, and csv.- But I am not sure what I have missed.    I want to click on this Calculate button. Infinity, is clearly not . But there is some dissent on whether or not zero is finite. I have seen authors use "finite" to indicate the value of $0$ is excluded as well as infinity.  Is there any rule about this? I have a "term reference" field, in a form that uses an auto-complete widget. I want to limit user input to terms in the vocabulary only, and output a message when a user tries to enter a non existing term.  I found the  module. However this does not work with forms that contain a field collection or a field group.  There is also a contributed patch . But I was wondering whether there was a simpler/cleaner solution like a module or maybe I missed an already existing way of doing it with latest drupal and taxonomy versions. Run Script on Wakeup? The UK Visas and Immigration Directorate publishes  that provides helpful tips that can result in successful visa applications. Section 2 of this guidance opens is entitled &quot;other documents you may want to provide&quot; (emphasis mine).  Section 2: other documents you may want to provide – all visitors This section provides guidance on the types of documents that you may want to provide to help us consider your application against the Immigration Rules. Previous travel documents/passports, which show previous travel. Financial documents showing that you have sufficient funds available.  These must clearly show that you have access to the funds, such as:  bank statements building society book proof of earnings such as a letter from employer confirming employment details (start date of employment, salary, role, company contact details) where a third party (who is either in the UK or will be legally in the UK at the time of your visit) is providing financial support to you e.g. a business, a friend or a relative, documents to show that they have sufficient resources to support you in addition to themselves and any dependant family should be provided   The first item is &quot;bank statements&quot; and this ties in with the , which says...  evidence that you can support yourself during your trip, eg bank statements or payslips from the last 6 months  (Note 'eg' is a Latin abbreviation meaning &quot;for example&quot;; this appears to be optional rather than a fixed requirement.) Question: How should someone interpret this such that the chances of success are maximized? How many statements should I submit? What are they looking for and what do my bank statements tell about me? Minimal cut edges number in connected Eulerian graph. I have to prove that Connected graph is Eulerian Graph if and only if the number of edges in minimal cut is even.  Implication from left to right. Well if $G$ is Eulerian Graph then degree of each vertex must be even. It's oblivious if i try to disconnect graph by removing all edges connected to the vertex with minimal degree. But minimal cut can be done also by dividing graph into 2 connected graphs (each graph with more then one vertex) and i have no idea how to deal with it.  Implication from right to left - completly no idea. Can you help me with my capacity planning? This is a  about  Related:      I have a question regarding capacity planning. Can the Server Fault community please help with the following:   What kind of server do I need to handle some number of users? How many users can a server with some specifications handle? Will some server configuration be fast enough for my use case? I'm building a social networking site: what kind of hardware do I need? How much bandwidth do I need for some project? How much bandwidth will some number of users use in some application?