A sequence {an} is defined as an=⎧⎪ ⎪⎨⎪ ⎪⎩1n,when n is odd−1n,when n is even where n∈N. Then the sum of first four terms is