Recent Submissions

2026/02/10 00:55:07 mkx2023275 solved Problem0007 (Line: 3)
2026/02/10 00:45:38 mkx2023275 solved Problem0006 (Line: 3)
2026/02/10 00:43:40 mkx2023275 solved Problem0005 (Line: 1)
2026/02/10 00:43:01 mkx2023275 solved Problem0004 (Line: 3)
2026/02/10 00:42:22 mkx2023275 solved Problem0003 (Line: 1)
2026/02/10 00:41:55 mkx2023275 solved Problem0002 (Line: 1)
2026/02/10 00:41:30 mkx2023275 solved Problem0001 (Line: 1)
2026/02/09 18:15:35 zhuyy solved Problem0041 (Line: 7)
2026/02/09 18:11:22 zhuyy solved Problem0039 (Line: 7)
2026/02/09 18:11:04 zhuyy solved Problem0040 (Line: 7)
2026/02/09 18:07:57 zhuyy solved Problem0039 (Line: 8)
2026/02/09 17:48:58 zhuyy solved Problem0038 (Line: 7)
2026/02/09 17:42:27 zhuyy solved Problem0037 (Line: 6)
2026/02/09 17:14:13 zhuyy solved Problem0037 (Line: 7)
2026/02/09 17:13:13 zhuyy solved Problem0036 (Line: 3)
2026/02/09 17:07:31 zhuyy solved Problem0035 (Line: 1)
2026/02/09 17:06:49 zhuyy solved Problem0034 (Line: 7)
2026/02/09 16:48:34 zhuyy solved Problem0033 (Line: 11)
2026/02/09 11:10:28 obj114514 solved Problem0007 (Line: 3)
2026/02/09 11:09:31 obj114514 solved Problem0006 (Line: 3)
2026/02/09 11:08:48 obj114514 solved Problem0005 (Line: 1)
2026/02/09 11:07:29 obj114514 solved Problem0004 (Line: 3)
2026/02/09 11:06:55 obj114514 solved Problem0003 (Line: 1)
2026/02/09 11:06:02 obj114514 solved Problem0002 (Line: 1)
2026/02/09 11:05:33 obj114514 solved Problem0001 (Line: 1)
2026/02/09 09:09:36 mathletesv solved Problem0018 (Line: 7)
2026/02/09 09:07:54 mathletesv solved Problem0045 (Line: 1)
2026/02/09 09:07:33 mathletesv solved Problem0053 (Line: 3)
2026/02/09 09:05:15 mathletesv solved Problem0036 (Line: 3)
2026/02/09 09:04:21 mathletesv solved Problem0035 (Line: 1)
2026/02/09 06:55:14 mathletesv solved Problem0017 (Line: 2)
2026/02/09 06:54:11 mathletesv solved Problem0016 (Line: 1)
2026/02/09 06:46:38 mathletesv solved Problem0011 (Line: 11)
2026/02/09 06:40:12 mathletesv solved Problem0010 (Line: 6)
2026/02/09 06:37:30 mathletesv solved Problem0010 (Line: 8)
2026/02/09 06:32:48 mathletesv solved Problem0009 (Line: 4)
2026/02/09 06:31:18 mathletesv solved Problem0008 (Line: 3)
2026/02/09 06:29:28 mathletesv solved Problem0007 (Line: 3)
2026/02/09 06:29:02 mathletesv solved Problem0006 (Line: 3)
2026/02/09 06:28:30 mathletesv solved Problem0005 (Line: 1)
2026/02/09 06:11:52 mathletesv solved Problem0028 (Line: 13)
2026/02/09 04:06:07 mathletesv solved Problem0028 (Line: 21)
2026/02/09 03:25:54 mathletesv solved Problem0028 (Line: 26)
2026/02/08 01:00:27 unputdownable solved Problem0083 (Line: 17)
2026/02/08 00:41:20 unputdownable solved Problem0010 (Line: 6)
2026/02/08 00:32:47 unputdownable solved Problem0013 (Line: 9)
2026/02/08 00:24:48 unputdownable solved Problem0010 (Line: 7)
2026/02/07 16:48:28 faaple solved Problem0013 (Line: 9)
2026/02/06 19:28:14 zhuyy solved Problem0032 (Line: 8)
2026/02/06 19:23:58 zhuyy solved Problem0026 (Line: 11)

News

About

Markov Algorithm

quote from wikipedia:

The Rules is a sequence of pair of strings, usually presented in the form of pattern → replacement. Each rule may be either ordinary or terminating.

Given an input string:

  1. Check the Rules in order from top to bottom to see whether any of the patterns can be found in the input string.
  2. If none is found, the algorithm stops.
  3. If one (or more) is found, use the first of them to replace the leftmost occurrence of matched text in the input string with its replacement. If the rule just applied was a terminating one, the algorithm stops.
  4. Go to step 1.

Note that after each rule application the search starts over from the first rule.

Syntax and Limitations

pattern:replacement This is ordinary rule. Replace first occurrence of pattern to replacement.
pattern::replacement This is terminating rule. Replace first occurrence of pattern to replacement and the algorithm stops.
empty pattern Empty string matches to the beginning of a string.
comments Lines not containing : are regarded as comments.
spaces Leading/trailing spaces in pattern/replacement are ignored.
step limit The number of replacements must not 50000 times.
string length limit The length of input string must not exceed 500 at any moment.
code length limit The length of the code must not exceed 1000 including comments and blanks.

Specifications

  • Your code will be accepted if it runs correctly for all testcases prepared by the problem writer.
  • The score is calculated based on the number of lines of replacement rules.
  • Scoring formula is min(900*Best / Yours + 100, 1000).
  • The fastest player who solved in fewest lines becomes Top player.
  • However the writer cannot become Top player and his/her solution isn't applied to Best.
  • Testcase hack is not allowed. If I find it, I will edit testcases and run rejudge.