首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何为一组事物分配一种

如何为一组事物分配一种
EN

Stack Overflow用户
提问于 2015-12-23 09:58:43
回答 1查看 33关注 0票数 0

我是新来通知7的。我一直在玩“鲍嘉”这个例子,它为服装提供了一些规则。

我有这样的东西:

代码语言:javascript
复制
The player wears a jacket, a jumper, a shirt, some underpants, a pair of men's blue jeans, a pair of socks.

现在,我想在服装上增加一项财产,例如:

代码语言:javascript
复制
An item of clothing is a kind of thing.

An item of clothing can be removable. An item of clothing is usually removable.

在这一点上,我似乎必须通过并显式地将播放机佩戴的每一项定义为item of clothing,例如:

代码语言:javascript
复制
A pair of socks is an item of clothing.  
A jumper is an item of clothing.  
A jacket is an item of clothing.  

...etc对玩家所穿的一切都很满意。

我想找到一种方法来告知everything worn by the player is an item of clothing,甚至everything wearable is an item of clothing。到目前为止,我还没有找到任何形式的这将编译,它有可能吗?

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2015-12-23 17:41:31

这不可能。你能做的最好就是:

代码语言:javascript
复制
The jacket, the jumper, the shirt, the underpants, the pair of men's blue jeans, 
and the pair of socks are item of clothing.
票数 2
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/34432986

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档