Magical BF 4
시간 제한1초메모리 제한1024 MB
행으로 읽으나 열로 읽으나 같은 BF 코드 격자를 만들어, F_1, F_2, k로 F_k를 계산해 M_0에 저장한다.
문제
John learned at school that in many East Asian languages texts can be written from left to right as well as from top to bottom. He got especially curious whether it's possible to write a text such that it can simultaneously be read both ways. John kept puzzling in programming class as well and now wants to write code such that it would solve the tasks when read by rows (top to bottom and left to right), as well as when read by columns (left to right and top to bottom). Naturally, he needed a suitable language for this and John chose a language called BF for experimenting.
The memory of a BF program is an infinite array with cells numbered from left to right (, , \ldots). Each cell contains a nonnegative integer that can be arbitrarily large. Additionally there is a data pointer that in the beginning of execution points to the leftmost cell ().
The execution of a program starts from its first command and in general after the execution of each command the program moves on to the next command in the sequence. Altogether there are six commands in the language, each one denoted by one character:
Help John write magical BF programs for solving the five tasks listed below.
As a solution to each task submit an grid of BF program code (where ). The code does not have to be the same when read by rows and by columns, but must solve the task correctly in both cases. The solution text can only contain the characters '>', '<', '+', '-', '[' and ']' and must completely fill the grid. For any allowed input, the code must not execute more than million commands.
Task: The cell contains an integer () and the cells and contain the integers and (, ). The elements of the sequence for are defined by the rule . Find the value of and write it into the cell . By the end of the execution all cells other than may contain any numbers.
Input example: 
Output example: 
예제
이 문제는 공개된 예제가 없습니다.