当前位置:网站首页>LeetCode 292.Nim 游戏(简单)
LeetCode 292.Nim 游戏(简单)
2022-08-10 05:32:00 【生信研究猿】
python
class Solution:
def canWinNim(self, n: int) -> bool:
# 对手如果最后给你剩下4块石头,你必输。
#所以石头总数不能是4的倍数,否则不管你拿几个,后手都可以把石头数量控制在4的倍数。
return n%4 != 0
边栏推荐
- GUI_AWT
- MySql 约束
- view【】【】【】【】
- 集合 set接口
- 转载fstream,ifstream的详细用法
- Link reading good article: What is the difference between hot encrypted storage and cold encrypted storage?
- The complex "metaverse" will be interpreted for you, and the Link Reading APP will be launched soon!
- Privatisation build personal network backup NextCloud
- 21天挑战杯MySQL——Day06
- 链读推荐:从瓷砖到生成式 NFT
猜你喜欢

Chain Reading Good Article: Jeff Garzik Launches Web3 Production Company

The latest and most complete digital collection sales calendar-07.26

基于 .NET Core MVC 的权限管理系统

Index Notes【】【】

图片批量添加水印批量加背景缩放批量合并工具picUnionV4.0

Collection工具类

先人一步,不再错过,链读APP即将上线!

棋类游戏-五子棋小游戏

卷积神经网络(CNN)实现mnist手写数字识别

链读|最新最全的数字藏品发售日历-08.02
随机推荐
win12 修改dns脚本
树结构——2-3树图解
opencv
树结构——二叉查找树原理与实现
MySql 约束
一个基于.Net Core 开源的物联网基础平台
网络安全作业
A little knowledge point every day
One step ahead, don't miss it again, the chain reading APP will be launched soon!
tinymce rich text editor
栈和队列
cesium add point, move point
cesium listens to map zoom or zoom to control whether the content added on the map is displayed
网络安全3
链读精选:星巴克着眼于数字收藏品并更好地吸引客户
我不喜欢我的代码
pytorch-09.多分类问题
Consensus calculation and incentive mechanism
Linux database Oracle client installation, used for shell scripts to connect to the database with sqlplus
毫米波雷达数据集Scorp使用