When I plot the graph, I get what one would expect, horizontal pieces on the unit intervals beginning with an even number and line segments with slope one on the unit intervals beginning with odd numbers for a function that is nondecreasing.
Hold is probably doing something similar by inhibiting the evaluation of something nonnumeric (?).. (With AccuracyGoal -> 10 I am just suppressing the error message.) Does that make sense?
I would like to greet all of you. Your comments and suggestions are very valuable, because my “mother milk” was FORTRAN IV on IBM7040. Now, after retirement, I have Mathematica Home Edition and this is a different kettle of fish.
My experiments:
NIntegrate[Hold[If[EvenQ[Floor[t]], 0, 1]], {t, 0, A}] works
NIntegrate[If[EvenQ[Floor[t]], 0, 1], {t, 0, A}] does not work
NIntegrate[Hold[If[Mod[Floor[t], 2] == 0, 0, 1]], {t, 0, A}] works
NIntegrate[If[Mod[Floor[t], 2] == 0, 0, 1], {t, 0, A}] works too
It seems to me that problem is connected with function EvenQ as can be deduced from yours experiments too..