sigmoid function and costFunction function code added and passing