Click here to Skip to main content
15,881,757 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Python
def ispossible(a, b, c, d) 
if __name__=='__main__':


What I have tried:

Python
def ispossible(a, b, c, d) 
if __name__=='__main__':
Posted
Updated 25-Sep-22 3:56am
v3
Comments
merano99 25-Sep-22 4:27am    
What should "if __name__=='__main__':" mean? Here only the pair of integers a, b is mentioned, what about b and c? The "following operations with a, b" are announced in the heading, but are completely missing in the question. The question would need to be revised as it makes no sense as it is. In addition, we expect a minimum amount of our own efforts here.
Richard MacCutchan 25-Sep-22 9:57am    
I have changed the tag from C++ to Python. However there is not enough information in your question to provide any useful answer.

1 solution

That's not C++: if looks more like Python, which is a very different language.

Even as Python however, there are at least two things wrong with it:
1) def requires a colon to indicate the end of the definition: Python Functions[^]
2) In Python, indentation is both significant, and very important: Python Indentation[^]
Without it, that code not only won't run, but if wouldn't do what you wanted it to anyway if it did ...

And since none of the parameters are used in the code you do show, we have no idea what error(s) you are getting, and we have no idea what you intended that code to do, we cannot help you any further ...
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900