Rock Paper Scissors Meta-Gaming Tournament This is a rock paper scissors competition. Algorithms will face each other in 100 rounds of rock paper scissors. Except that the algorithms will also be able to read the source code of each other!
Leaderboard
1.  Chaos Bot (by Aiden4) - 27 Points, 168 bytes
2.  Anti-99%-of-posts (by Lyxal) - 24 Points, 489 bytes
3.  Psuedo-Hash Cycle (by qwatry) - 22 Points, 143 bytes
4.  If-If (by PkmnQ) - 20 Points, 63 bytes
5.  Biased-Cycler (by HighlyRadioactive) - 19 Points, 17 bytes
6.  Cycler (by petStorm) - 16 Points, 17 bytes
7.  Craker (by petStorm) - 16 Points, 58 bytes
8.  Lookup (by petStorm) - 16 Points, 61 bytes
9.  RadiationBot v0.1 (by HighlyRadioactive) - 16 Points, 121 bytes
10. Custom (by petStorm) - 15 Points, 56 bytes
11. Anti-Cycler (by Lyxal) - 14 Points, 17 bytes
12. Mr. Paper - 13 Points, 58 bytes
13. PseudoRandom (by HighlyRadioactive) - 12 Points, 89 bytes
14. Itna-Cycler (by petStorm) - 11 Points, 17 bytes
15. Mr. Rock - 11 Points, 57 bytes
16. Lycler (by petStorm) - 10 Points, 24 bytes
17. Mr. Scissors - 10 Points, 61 bytes

Submissions are graded automatically via an online judge
View Online Judge
The Competition
Your code will be a javascript anonymous function (sorry, other languages aren't supported!) that takes in two arguments:

The source code of your opponent AI (as a string)
The current round number

It should then return one of &quot;R&quot;, &quot;P&quot;, or &quot;S&quot;, indicating that it will throw a rock, paper, or scissors for that round.
Your code must follow these rules, otherwise it will be disqualified:

Your code may not be longer than 500 bytes
Your function must be pure

That is, if your function is given the same set of arguments, your code must always return the same result
This is to ensure that the tournament results are consistent


eval() calls are banned!

If this were allowed, two submissions with eval() would end up calling each other in an endless loop which would never terminate.
(See the discussion in the comments for more details/reasoning)


Your code may not:

Access external resources (e.g. make web fetch/get requests)
Attempt to modify or tamper with the judge system code
Cause excessive lag or time delay
Modify any globals or object prototypes
Attempt to do an XSS attack or any other sketchy/illegal stuff



Example submission
(code, round) =&gt; {
  if (round === 1) {
    // Throw rock if it's the first round
    return &quot;R&quot;;
  }
  else if (code.includes('&quot;R&quot;')) {
    // Throw paper if the opponent code includes &quot;R&quot;
    return &quot;P&quot;;
  } else {
    // Otherwise throw scissors
    return &quot;S&quot;;
  }
}

Tournament structure
Every submission will play rounds of rock paper scissors against every other submission. Each submission will play 100 rounds with each other submission.
To get the ball rolling, the following three functions will be submitted by default and will not be counted in the final leaderboard:
(code, round) =&gt; {
  // Always throw rock
  return &quot;R&quot;;
}

(code, round) =&gt; {
  // Always throw paper
  return &quot;P&quot;;
}

(code, round) =&gt; {
  // Always throw scissors
  return &quot;S&quot;;
}

Scoring
A submission gains 2 points for winning against another submission, and 1 point for tying against another submission (no points are awarded for losses).
Rankings are ordered by most points. If two submissions have the same number of points, they will be ranked in order of least bytes. If two submissions have the same number of points and bytes, the older submission will be ranked higher.
Judging &amp; Testing
Post your submissions here, I will periodically add submissions to the online judge which will automatically rank each algorithm.
You can also test your algorithms using the online judge testing area. A testing area is provided at the bottom to test different algorithms against each other.
Anti-99%-of-posts
(code,r)=&gt;{var S=&quot;S&quot;;var R=&quot;R&quot;;var P=&quot;P&quot;;var x=S+R+P;var y=R+P+S;var z=P+S+R
if(code.includes(&quot;17&quot;)){return &quot;P&quot;;}
else if(code.includes(&quot;[r%2]&quot;)){return&quot;RR&quot;[r%2]}
else if(code.includes(&quot;[r%3]&quot;)){
if (code.includes(x)){return (R+P+S)[r%3];}
else if(code.includes(y)){return (P+S+R)[r%3];}
else if(code.includes(z)){return (S+R+P)[r%3];}
}else{if(code.includes(&quot;scissors&quot;)){return &quot;R&quot;}else if (code.includes(&quot;rock&quot;)){return &quot;P&quot;}else if (code.includes(&quot;paper&quot;) ){return &quot;S&quot;}else{return &quot;P&quot;}}}

Haha. Testing it on submissions gives either a win or a tie.