Levels and gamma transitions of40K studied by neutron capture