try: x=1 while x: x=int(input()) print(0 if x%3 else x//3*"2") except:pass