Data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 7387c8f97b
commit cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions

View file

@ -0,0 +1,30 @@
randomTorH = function()
if rnd < 0.5 then return "T" else return "H"
end function
if rnd < 0.5 then
playerSeq = input("Input your sequence (e.g. HTH): ").upper
if playerSeq[1] == "T" then compSeq = "H" else compSeq = "T"
compSeq = compSeq + playerSeq[:2]
print "I choose: " + compSeq
else
compSeq = randomTorH + randomTorH + randomTorH
print "I choose: " + compSeq
playerSeq = input("Input your sequence (e.g. HTH): ").upper
end if
print "Here we go..."
seq = ""
while true
flip = randomTorH
print flip
seq = seq + flip
if seq[-3:] == playerSeq then
print "You win!"
break
else if seq[-3:] == compSeq then
print "I win!"
break
end if
wait
end while