also doesn’t give an error. So I think maybe the error is coming from somewhere else in your code, is that possible? Or you edited <something> between trying out both?
Maybe this helps you find it: the error indicates that you are trying to add a range (for example, 3:10) to an integer (for example, (3:10) + 42).