I'm guessing that you meant 100 <= i < 0 rather than 100 <= f(i) < 0
f[n_] := PDF[BinomialDistribution[100, .1], n]
Maximize[{f[j], 0 < j <= 100}, j, Integers]
{0.131865, {j -> 10}}
Maximize[{f[j], 0 < j <= 100, Element[j, Integers]}, j]
{0.131865, {j -> 10}}
If f and cons are linear or polynomial, Maximize will always find a
global maximum. In cases where Maximize only finds a local maxima,
you can use an exhaustive search.
data = Table[{n, f[n]}, {n, 0, 100}];
Select[data, #[[2]] == Max[data[[All, 2]]] &]
{{10, 0.131865}}
Bob Hanlon