Recent Submissions

2026/09/06 17:28:11 yao99 solved Problem0056 (Line: 112)
2026/09/06 16:16:02 yao99 solved Problem0055 (Line: 31)
2026/09/06 16:09:09 yao99 solved Problem0054 (Line: 18)
2026/09/06 15:45:24 yao99 solved Problem0053 (Line: 3)
2026/09/06 15:39:56 yao99 solved Problem0085 (Line: 9)
2026/09/06 15:35:37 yao99 solved Problem0084 (Line: 13)
2026/09/06 15:06:21 yao99 solved Problem0083 (Line: 10)
2026/09/06 14:39:50 yao99 solved Problem0082 (Line: 12)
2026/09/06 14:28:06 yao99 solved Problem0081 (Line: 8)
2026/09/06 14:06:38 yao99 solved Problem0080 (Line: 2)
2026/09/06 14:00:52 owoovo solved Problem0010 (Line: 7)
2026/09/06 13:48:45 yao99 solved Problem0079 (Line: 5)
2026/09/06 13:41:29 yao99 solved Problem0078 (Line: 1)
2026/09/06 13:29:45 yao99 solved Problem0077 (Line: 14)
2026/09/06 13:19:15 owoovo solved Problem0009 (Line: 4)
2026/09/06 13:18:33 owoovo solved Problem0007 (Line: 3)
2026/09/06 13:06:15 owoovo solved Problem0006 (Line: 3)
2026/09/06 13:05:53 owoovo solved Problem0005 (Line: 1)
2026/09/06 13:05:33 owoovo solved Problem0004 (Line: 3)
2026/09/06 13:05:14 owoovo solved Problem0003 (Line: 1)
2026/09/06 13:04:50 owoovo solved Problem0002 (Line: 1)
2026/09/06 13:04:27 owoovo solved Problem0001 (Line: 1)
2026/09/06 13:04:04 owoovo solved Problem0008 (Line: 3)
2026/09/06 13:03:46 yao99 solved Problem0076 (Line: 13)
2026/09/06 00:08:48 yao99 solved Problem0076 (Line: 19)
2026/09/05 23:48:08 yao99 solved Problem0075 (Line: 11)
2026/09/04 23:18:00 xiaorui2007 solved Problem0019 (Line: 5)
2026/09/02 19:22:29 xiaorui2007 solved Problem0066 (Line: 10)
2026/08/30 01:31:38 zzk solved Problem0029 (Line: 8)
2026/08/30 01:30:00 zzk solved Problem0029 (Line: 7)
2026/08/30 00:55:43 zzk solved Problem0028 (Line: 18)
2026/08/30 00:52:05 zzk solved Problem0028 (Line: 19)
2026/08/29 18:14:16 JoatMao solved Problem0027 (Line: 12)
2026/08/29 17:59:29 JoatMao solved Problem0067 (Line: 8)
2026/08/29 17:55:29 JoatMao solved Problem0067 (Line: 10)
2026/08/29 17:55:04 JoatMao solved Problem0067 (Line: 11)
2026/08/29 17:50:12 JoatMao solved Problem0066 (Line: 10)
2026/08/29 17:43:50 JoatMao solved Problem0065 (Line: 9)
2026/08/29 17:39:56 JoatMao solved Problem0085 (Line: 9)
2026/08/29 17:39:09 JoatMao solved Problem0085 (Line: 16)
2026/08/29 17:23:53 JoatMao solved Problem0082 (Line: 12)
2026/08/29 17:19:20 JoatMao solved Problem0081 (Line: 8)
2026/08/29 17:17:59 JoatMao solved Problem0080 (Line: 2)
2026/08/29 17:16:44 JoatMao solved Problem0079 (Line: 4)
2026/08/29 17:15:52 JoatMao solved Problem0079 (Line: 5)
2026/08/29 17:14:04 JoatMao solved Problem0078 (Line: 1)
2026/08/29 17:10:36 JoatMao solved Problem0069 (Line: 3)
2026/08/29 17:07:00 JoatMao solved Problem0064 (Line: 6)
2026/08/29 17:03:25 JoatMao solved Problem0064 (Line: 9)
2026/08/29 17:00:40 JoatMao solved Problem0063 (Line: 3)

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.