Little Artem got n stones on his birthday and now wants to give some of them to Masha. He knows that Masha cares more about the fact of receiving the present, rather than the value of that present, so he wants to give her stones as many times as possible. However, Masha remembers the last present she received, so Artem can't give her the same number of stones twice in a row. For example, he can give her 3 stones, then 1 stone, then again 3 stones, but he can't give her 3 stones and then again 3 stones right after that.

How many times can Artem give presents to Masha?


-----Input-----

The only line of the input contains a single integer n (1 ≤ n ≤ 10^9) — number of stones Artem received on his birthday.


-----Output-----

Print the maximum possible number of times Artem can give presents to Masha.


-----Examples-----
Input
1

Output
1

Input
2

Output
1

Input
3

Output
2

Input
4

Output
3



-----Note-----

In the first sample, Artem can only give 1 stone to Masha.

In the second sample, Atrem can give Masha 1 or 2 stones, though he can't give her 1 stone two times.

In the third sample, Atrem can first give Masha 2 stones, a then 1 more stone.

In the fourth sample, Atrem can first give Masha 1 stone, then 2 stones, and finally 1 stone again.

Difficulty: interview

Starter code:

Solutions:
n = int(input())
if n % 3 == 0:
    print(2 * (n // 3))
else:
    print(2 * (n // 3) + 1)


a = int(input())
print(a//3*2+[0,1][a%3!=0])

n = int(input())

sol = (n//3) * 2

if n % 3:
    sol += 1

print(sol)


n = int(input())
answer = (n//3)*2
n = n%3
if n != 0:
    print(answer+1)
else:
    print(answer)

n = int(input())
g = 3*(n//3)
if n-g >= 1:
    print(2*(n//3)+1)
else:
    print(2*(n//3))


n = int(input())
print((n // 3)* 2+ (n % 3 != 0))


x = int(input())
core = (x//3)*2
l= x-(x//3)*3
if l == 0:
	print (core)
else:
	print (core+1)

n = int(input())
print(n // 3 * 2 + (n % 3 > 0))

parse_int = lambda: list(map(int, input().split()))

n = int(input())

res = (n//3)*2
if n%3 > 0:
    res += 1
print(res)

a = int(input())
print((a//3)*2+bool(a%3))


n = int(input())

t = (n // 3) * 2

if n % 3 != 0:
	t += 1
print(t)

def solve():
    N = int(input())

    d3 = N // 3

    m3 = N % 3

    ans = d3 * 2

    if m3 == 1:
        ans += 1
    elif m3 == 2:
        ans += 1

    print(ans)


def __starting_point():
    solve()

__starting_point()

def __starting_point():
    #n, m = list(map(int, input().split()))
    #s = list(input().split())
    n = int(input())
    if n % 3 == 0:
        print(2 * (n // 3))
    else:
        print(2 * (n // 3) + 1)
    

__starting_point()

n=int(input())
ans=0
if n%3==0:
    ans+=(n//3)*2
elif n%3==1:
    ans+=(n//3)*2+1
elif n%3==2:
    ans+=(n//3)*2+1
print(ans)

n = int(input())
if n == 2:
    print(1)
else:
    print(2 * (n // 3)  + (1 if n % 3 != 0 else 0))

#!/usr/bin/env python3
# 669A_presents.py - Codeforces.com/problemset/problem/669/A by Sergey 2016

import unittest
import sys

###############################################################################
# Presents Class (Main Program)
###############################################################################


class Presents:
    """ Presents representation """

    def __init__(self, test_inputs=None):
        """ Default constructor """

        it = iter(test_inputs.split("\n")) if test_inputs else None

        def uinput():
            return next(it) if it else sys.stdin.readline().rstrip()

        # Reading single elements
        [self.n] = list(map(int, uinput().split()))

    def calculate(self):
        """ Main calcualtion function of the class """

        result = (self.n // 3) * 2
        if self.n % 3 != 0:
            result += 1

        return str(result)

###############################################################################
# Unit Tests
###############################################################################


class unitTests(unittest.TestCase):

    def test_single_test(self):
        """ Presents class testing """

        # Constructor test
        test = "1"
        d = Presents(test)
        self.assertEqual(d.n, 1)

        # Sample test
        self.assertEqual(Presents(test).calculate(), "1")

        # Sample test
        test = "2"
        self.assertEqual(Presents(test).calculate(), "1")

        # Sample test
        test = "3"
        self.assertEqual(Presents(test).calculate(), "2")

        # My tests
        test = "5"
        self.assertEqual(Presents(test).calculate(), "3")

        # Time limit test
        # self.time_limit_test(5000)

    def time_limit_test(self, nmax):
        """ Timelimit testing """
        import random
        import timeit

        # Random inputs
        test = str(nmax) + " " + str(nmax) + "\n"
        numnums = [str(i) + " " + str(i+1) for i in range(nmax)]
        test += "\n".join(numnums) + "\n"
        nums = [random.randint(1, 10000) for i in range(nmax)]
        test += " ".join(map(str, nums)) + "\n"

        # Run the test
        start = timeit.default_timer()
        d = Presents(test)
        calc = timeit.default_timer()
        d.calculate()
        stop = timeit.default_timer()
        print(("\nTimelimit Test: " +
              "{0:.3f}s (init {1:.3f}s calc {2:.3f}s)".
              format(stop-start, calc-start, stop-calc)))

def __starting_point():

    # Avoiding recursion limitaions
    sys.setrecursionlimit(100000)

    if sys.argv[-1] == "-ut":
        unittest.main(argv=[" "])

    # Print the result string
    sys.stdout.write(Presents().calculate())

__starting_point()


n = int(input())

print((n // 3) * 2 + (1 if n % 3 else 0))


def solve(n):
    x = n // 3
    c = 2 * x
    n -= 3 * x
    if n:
        c += 1
    return c

n = int(input())

print(solve(n))


n = int(input())
x=2*(n//3)
if n%3 != 0:
    x += 1
print(x)



#listInput = list(map(int,input().split()))
num = int(input())
numleft = num%3
out = 2*(num//3)
if numleft == 0:
    print(out)
else:
    print(out + 1)

n = int(input())
print((n // 3) * 2 + (n % 3 > 0))


n = int(input())
print(int(n/3)*2 + (0 if n%3==0 else 1))

a = int(input())
b=int(a/3)*2
c=a%3
if c==0:
    print(b)
else:
    print(b+1)


n = int(input())
ans = (n - 1) // 3 * 2 + int(n % 3 == 0) + 1
print(ans)


n = int(input())
if n % 3 == 0:
    print(n // 3 * 2)
elif n < 3:
    print(1)
else:
    print(n // 3 * 2 + 1)