Arithmetic_Formatter: Understanding Replit Error Messages

Unfortunately, even after reading through other questions in forum relating to Arithmetic_Formatter, I do not understand Replit’s Error messages.

My code seems to work for all conditions when i test it, but it fails every Replit test. Any pointers would be greatly appreciated, including critisicm on style…https://replit.com/@ianGutch/boilerplate-arithmetic-formatter-4#arithmetic_arranger.py

The biggest issue that trips people up is putting extra spaces at the end of each line.

-   1         1
+   1         1    
?              ++++

Here are some excess spaces at the end.

The other thing, you are supposed to return the error message, not print it.

1 Like

thank you very much.

How did you figure the problem in the text box you posted though? I am assuming you pulled it from “test_template[test_two_problems_arrangement2” , but is this something is easily seen by just looking at Replit test console or were you explicitly looking for it? I had seen your replies to other questions on the forum, but couldn’t figure out how to tell.
I just copied the three lines you pointed out, and pasted it in Visual Studio, but that seems like the only way I can see there are 4 spaces at the end of the bottom line.
Thanks, and sorry if my questions aren’t the best.

Sorry I don’t understand the question.
I went to your replit, ran the code, copy-pasted some lines from the error message into a code-block in the forum and removed the leadin “E ” as the forum then auto-colors the error-messages as you see.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.