here is the error output:
File “/users/cDesktop/simp.py”, line 71
print(“sig”, str(nsig.getVal()), “bkg”, str(nbkg.getVal()))
^
SyntaxError: invalid syntax
Thanks in advance
here is the error output:
File “/users/cDesktop/simp.py”, line 71
print(“sig”, str(nsig.getVal()), “bkg”, str(nbkg.getVal()))
^
SyntaxError: invalid syntax
Thanks in advance
Hello @wolfram420,
this is more a generic python question rather than a ROOT related one, it’s a bit out of scope of this forum ![]()
However, the invalid syntax error may be raised in many situations, I list a few
print(Hello) instead of print("Hello").iff instead of if.+ operator when trying to add two numbers.Good luck,
Monica
It looks like the quotation marks around the strings "sig" and "bkg" appear to be curly quotes (“ ”) instead of standard straight quotes (" "). Python and C++ require standard quotes for strings.
Thanks for you reply. I realize that I missed a right parenthesis above.
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.