S MATRIX FOR THE ONE-DIMENSIONAL N-BODY PROBLEM WITH REPULSIVE OR ATTRACTIVE delta-FUNCTION INTERACTION.