import sys, time, random from collections import deque, Counter, defaultdict input = lambda: sys.stdin.readline().rstrip() ii = lambda: int(input()) mi = lambda: map(int, input().split()) li = lambda: list(mi()) inf = 2 ** 63 - 1 mod = 998244353 op = [] def plus(i, j, k): a[i] = a[j] + a[k] assert a[i] <= 2 ** 64 op.append(('plus', i + 1, j + 1, k + 1)) def div(i, j): a[i] = a[j] // 2 assert a[i] <= 2 ** 64 op.append(('div', i + 1, j + 1)) x = random.randint(0, 10 ** 9) a = [0] * 100 a[0] = x a[1] = 1 #a[0] = (x + 1) << 32 とする plus(0, 0, 1) for _ in range(16): plus(0, 0, 0) plus(3, 0, 3) for i in range(16): for j in range(2): div(3, 3) plus(2, 2, 3) for _ in range(16): div(2, 2) assert x // 3 == a[2] for _ in range(1000 - len(op)): plus(0, 0, 0) print(len(op)) for v in op: print(*v)