Company: Adobe_12july
Difficulty: medium
Sequence of Balance Problem Description In the mystical land of Arrayland, there exists a legendary artifact known as the Sequence of Balance. This artifact is an array of numbers that holds great power, but over time its harmony has been disturbed. The wise mathematician Eldrin, the guardian of Arrayland, has been given the task of restoring its lost balance. The artifact is represented as an array A of size N that contains a mixture of positive, negative and zero values. To restore harmony, Eldrin must transform the array into a "good" sequence, which follows these sacred rules: The first element of the array must be negative . The last element of the array must be positive . There must exist an index K (1 <= K <= N-1) such that: all elements from index 1 to K (inclusive) are negative , and all elements from index K+1 to N (inclusive) are positive . Eldrin has a special power: in a single operation he can change any one number in the array into any other integer. The power is l