Lemma on logarithmic derivatives and holomorphic curves in algebraic varieties