登录
首页 » Python » 猜拳游戏(石头剪刀布.py)

猜拳游戏(石头剪刀布.py)

于 2020-11-30 发布
0 349
下载积分: 1 下载次数: 0

代码说明:

# 石头 0 剪刀 1 布 2 import randombot = random.randint(0, 2)player = int(input("输入您的结果")) if (player == 1) and (bot == 2) or (player == 2) and (bot == 0) or (player == 0) and (bot == 1): print("玩家获胜") elif player == bot: print("你们打成平手") else: print("电脑获胜")

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • Python贪吃蛇游戏实例
    此实例为Python写的一个简单的贪吃蛇游戏,提供Python入门者学习
    2017-11-16下载
    积分:1
  • 告白树(基于turtle)
    【实例简介】python 画表白树,树叶上可以写上心爱的人的名字,适用于表白场景
    2021-06-02 00:31:40下载
    积分:1
  • 影评情感分析数据集ACLIMDB
    【实例简介】 数据集一共50000条数据。25000条训练数据,25000条测试数据。
    2021-08-01 00:31:08下载
    积分:1
  • python智能小车
    【实例简介】 python智能小车
    2021-07-30 00:31:11下载
    积分:1
  • 机器学习-岭回归实现
    通过岭回归实现 数据标签的预测
    2020-12-05下载
    积分:1
  • LSTM入门正弦波序列预测
    LSTM入门学习,正弦波序列预测         for i, input_t in enumerate(input.chunk(input.size(1), dim=1)):             h_t, c_t = self.lstm1(input_t, (h_t, c_t))             h_t2, c_t2 = self.lstm2(h_t, (h_t2, c_t2))             output = self.linear(h_t2)  # output.shape:[batch,1]             outputs = [output]  # outputs.shape:[[batch,1],...[batch,1]], list composed of n [batch,1],         for i in range(future):  # if we should predict the future             h_t, c_t = self.lstm1(output, (h_t, c_t))             h_t2, c_t2 = self.lstm2(h_t, (h_t2, c_t2))             output = self.linear(h_t2)  # output.shape:[batch,1]             outputs = [output]  # outputs.shape:[[batch,1],...[batch,1]], list composed of n [batch,1],         outputs = torch.stack(outputs, 1).squeeze(2)  # shape after stack:[batch, n, 1], shape after squeeze: [batch,n]         return outputs
    2021-06-30 00:31:01下载
    积分:1
  • 《动手学习深度学习》Pytorch 相关源码
    Dive Into Deep Learning
    2020-12-08下载
    积分:1
  • python django项目源码学生管理
    python django项目源码学生管理
    2021-05-06下载
    积分:1
  • 实体识别(Bert-BiLSTM-CRF-pytorch版源代码)
    Bert-BiLSTM-CRF-pytorch版源代码,实体识别
    2021-10-22 00:31:09下载
    积分:1
  • 时间序列预测lstm
    【实例简介】
    2021-08-06 00:31:00下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载