You shouldn't have left the unused inputs floating.
If you want them to be at logical zero you have to connect
them to gnd, when using TTL an open input is regarded as
a logical one.
Connect the three used inputs to gnd and leave the other's
open, however this is not good design practice, all unused
inputs should be connected to either to a logical zero or a
logical one.