Log inSign up
Problems / P58

Large number multiplication (think)

500 ptsthinkqwen3-0.6bCases 16max 320 tokensSet by dongbinna
Added October 11.
0 solved1 attempted46 submissions

Statement

You multiply two four digit numbers. This is the hardest calculation on this site.

InputExpected output
4728 * 351916637832

Grading reads only the last integer of the output, so you may write out a long working.

Input

  • A string of the form X * Y arrives as the input.

  • The input arrives as one line.

  • X is a natural number between 1948 and 9372.

  • Y is a natural number between 1763 and 9205.

  • There is one space between each number and the operator.

Output

  • Print the result of the multiplication on the first line as an integer.

  • The output value is a natural number between 10336088 and 37520236.

  • Do not add any other characters.

  • Not a single character may differ from the expected value.

Requirements

  • The input is of the form A * B, four digits by four digits.
  • The output is the product as an integer.
  • This is think mode. You fill in the thinking block of the assistant turn yourself. Grading looks only at what comes after </think>.
  • Only the last integer of the output is read. You may write the working before it.
  • There are 16 cases, and 5 of them show the input together with the expected output. The rest show the input only.
  • Model output is accepted up to 320 tokens.
  • You have to pass all 16 cases to solve this.
Read the requirements carefully before solving. Gaming the score through prompt injection or similar tricks can get you sanctioned if caught.

Examples

5 public cases. Judging also uses hidden cases. You have to pass all 16 cases to solve this.

Input
Expected output
4728 * 3519
16637832
8061 * 2947
23755767
6315 * 4082
25777830
9204 * 1763
16226652
5837 * 6428
37520236

Notes

Background that helps with solving. The rules you have to follow are in the input and output specs and the requirements above.

Because this is think mode, you can fill in the model's thinking block yourself. If you write how to split the work into the thinking block in advance, the model follows that path. Splitting it with the distributive law is the usual approach.

If you plant too long a thought, </think> never shows up inside the token budget and there is no answer at all. Measure for yourself whether to plant a short thought and let the model carry on, or plant a long one and leave only the arithmetic.

Prompt

Qwen3 0.6B
Input to preview
This is the exact text that goes into the model (Sample input 1 is used here.)
This problem wraps your text in a chat template, so the exact text can only be shown once the model is loaded. Load Qwen3 0.6B first with the button below.
0 chars
To solve problems you need to log in.