Share your repls and programming experiences

← Back to all posts
Rock Paper Scissors with Smart AI player
OrionLee (26)

Please open it on itself at the top right, alot of stats will be shown like win rate, win streaks, and things like the % where u use "Rock" for example.

You will be asked to state the number of matches you want to play with the AI, after the [no. of matches] you could continue or quit if you wish. Pick "1" for Rock, "2" for Scissors and "3" for paper.

Please give some feedback to my AI after experiencing it. Thanks and have fun!

This is one of my first code i created every since i learned python, i hope you enjoy.

P.S Try not to look at the code as it gives away the AI's coding
P.S.S Try to play "seriously" for better AI experience, imagine that the AI is a human you are facing, play about 10-20 matches so that the AI have time to learn your style.

Here is my friend's score against the AI after 30 matches with it

It may not look that exciting, however my friend is really smart and have made reasonable and logical choices for all 30 matches, so you can expect the AI to be difficult (The numbers scares me because it was clearly evident that the AI was on par as him when looking at the datas, further matches may eventually resulted a loss to him as the AI would learn even more)

DenisWhitehead (1)

A rather smart AI, it really makes you think hard about your next play though it may just be a simple RPS game

OrionLee (26)

@DenisWhitehead Thanks for the compliment!

minx28 (342)

you know you can just do

import replit

to clear console

OrionLee (26)

@minx28 oh i see thanks, sorry im new to coding and python is my first programming language im currently learning now

Zavexeon (1041)

This brings back memories to one of my oldest programs.

+1 For nostalgia. (even though I made that like only a year ago lol)

themaka (183)

Well done AI -- and I like that you kept track (and displayed) stats. Made it more enjoyable!

OrionLee (26)

@themaka Thanks for appreciating it!

annojia (2)

not bad but wait until you see my AI toaster

OrionLee (26)

@annojia XD Thanks! We shall see..

lydiahallie (32)

Nice, well done!! I played it 5 x 10 matches, and only won it 2 times haha! It's impressive :)