1. A scrambling code generating apparatus in a mobile communication system, comprising: a resister memory which receives a state value of a scrambling code from an upper layer to set initial values thereof; a generator which generates an extended state value by performing a mask operation based on initial values and input information; and a scrambling code generator which generates a scrambling code based on at least a first state value which is continuously selected from among the extended state value, a second state value generated based on at least state values (L,R) which correspond to the first state value, and an initial value which has not been used from the initial values.