题目描述
Problem Description
You are given a positive integer $ N $. You need to create an expression using the characters 012345+-*/ that evaluates to $ N $ and is no more than 50000 characters long. Note that characters 6789%^() are not allowed. Concatenating digits to form numbers of two or more digits is prohibited. Also, starting the expression with a minus sign or using the minus sign as a unary operator is prohibited.
(Examples of prohibited expressions: 8-2*(4*2), 55+42, -4+2*4, 5*5+3*-2.) Additionally, due to judge constraints, if any term in the expression exceeds $ 10^{800} $, it will be considered incorrect. The expression should evaluate * / operations first. When priorities are the same, calculations should be performed from left to right. Division should truncate the decimal part (refer to sample 3).
Input Format
$ N $
Output Format
Output the expression on a single line.
【Subtasks】
Subtask $ 1 $ \[$ 5 $ points\] $ n < 10000 $
Subtask $ 2 $ \[$ 10 $ points\] $ n < 10^{18} $
Subtask $ 3 $ \[No specific limit\] n is a 150-digit integer. However, n is uniformly randomly generated within these constraints. There are 10 cases, and your score is the minimum score per case. The score per case is determined by the length of your generated expression $ L $, calculated as $ 3777.4826/sqrt(L) $.
Sample Input and Output
Sample Input #1
7
Sample Output #1
5+2
Sample Input #2
19
Sample Output #2
5*5-2*3
Sample Input #3
24
Sample Output #3
5*5/4*4
Notes/Hints
Constraints
$ 1 ≦ N ≦ 10^{150} $
Sample Explanation 1
5+2 = 7, which is correct. Other correct expressions include 3+4, 2*3+1, and 3*5/2.
Sample Explanation 3
In this case, 5*5/4 is calculated first, truncating the decimal part to become $ 6 $, and then *4 is performed, resulting in $ 24 $.
输入格式
见题面 Input 部分
输出格式
见题面 Output 部分