Intransitive verb

本文介绍了英语语法中不及物动词的概念,这类动词后不接宾语,并提供了多个例句帮助理解。

In grammar, an intransitive verb does not take an object. In more technical terms, an intransitive verb has only one argument (its subject), and hence has a valency of one. For example, in English, the verbs sleep, complain and die, are intransitive.

Some examples of sentences with intransitive verbs:

  • Harry will not sleep until sunset.
  • You complain too much.
  • He died on Saturday.

 

题目描述 某人有 N N 个单词、 C C 个逗号和 P P 个句号( 1 ≤ P , C ≤ N ≤ 1 0 3 1≤P,C≤N≤10 3 )。他只能使用词库中出现的词和标点符号次数。帮助他输出一个包含尽可能多词的句子序列。 这门语言只有四种词性:noun(名词)、transitive-verb(及物动词)、intransitive-verb(不及物动词)或 conjunction(连词)。 每两个连续单词之间必须用空格隔开。标点符号只有两种:句号和逗号。 当一个句号或逗号出现在单词后面时,它直接跟在单词后面,如果后面还有单词,则再跟一个空格。 一个句子必须符合以下两种格式之一: 类型 1:名词 + 不及物动词。 类型 2:名词 + 及物动词 + 名词(至少一个名词跟在及物动词后面)。除了第一个跟在及物动词后的名词外,每个后续名词前必须有一个逗号。 两个句子可以用一个连词连接成一个复合句,复合句不能再与其他句子或复合句连接。 每个句子(或复合句,如果两个句子被连接)必须以句号结束。 每个输入文件包含 T T( 1 ≤ T ≤ 100 1≤T≤100)个独立的测试用例。 输入格式 第一行输入 T T,表示测试用例数量。 每个测试用例的格式如下: 第一行是三个整数 N , C , P N,C,P。 接下来的 N N 行,每行包含两个字符串:第一个是单词(由 1 到 10 个小写字母组成),第二个是它的词性,可能是 noun、transitive-verbintransitive-verb 或 conjunction。 同一个单词可能出现多次,但每次出现时词性相同。 输出格式 对于每个测试用例: 第一行输出可能使用的最大单词数量。 第二行输出任意一个达到最大单词数量的句子序列。任何有效的序列都会被接受。 评测程序对空格敏感,请确保不要输出多余的空格,尤其是每行末尾。 样例输入: 3 1 1 1 bessie noun 10 5 4 bessie noun taught transitive-verb flew intransitive-verb elsie noun farmer noun john noun and conjunction and conjunction nhoj noun mooed intransitive-verb 24 5 4 but conjunction bessie noun taught transitive-verb flew intransitive-verb elsie noun farmer noun john noun and conjunction and conjunction nhoj noun mooed intransitive-verb bob noun impressed transitive-verb cow noun impressed transitive-verb leaped intransitive-verb elsie noun bella noun buttercup noun pushed transitive-verb mooed intransitive-verb envy noun john noun nhoj noun 样例输出: 0 9 nhoj mooed. farmer taught elsie, bessie and john flew. 23 nhoj mooed. nhoj impressed john, farmer, elsie, bessie and cow impressed bob. bella pushed elsie and buttercup flew. envy mooed but john leaped. 第一个测试用例中,唯一有效的序列是空序列。 对于接下来的两个测试用例,可以构造一个句子序列,只少用一个单词。 数据范围 测试点 1-6: N ≤ 10 N≤10 测试点 7-11: N ≤ 100 N≤100 测试点 12-16: N ≤ 1000 N≤1000 编号模 5 余 2 的测试点:没有transitive-verb(及物动词) 编号模 5 余 3 的测试点:没有intransitive-verb(不及物动词) 编号模 5 余 4 的测试点:没有conjunction(连词) c++代码
10-31
P2607. [USACO 23OPEN.B] Moo Language 题目描述 农夫约翰对与其他奶牛更好地交流感兴趣,因此他决定学习“moo”语言! Moo语言实际上与英语非常相似,但更为简约。它只有四种类型的词:名词、及物动词、不及物动词和连词。每两个连续的词之间必须用一个空格隔开。标点符号也只有两种类型:句号和逗号。当一个单词后面跟着句号或逗号时,它直接出现在该单词后面,如果下一个单词出现,则跟着一个空格。 一个句子必须遵循以下格式之一: 类型1:名词 + 不及物动词。 类型2:名词 + 及物动词 + 名词(S)。具体来说,至少要有一个名词跟在及物动词后面,而且除了第一个名词之外,每个后续名词前必须有一个逗号。 如果在它们之间放置一个连词,那么两个句子可以组合成一个复合句。结果得到的复合句不能进一步与其他句子或其他复合句组合在一起。每个句子(或复合句,如果两个句子被连接在一起)必须以句号结束。 农夫约翰有一个由 N N个单词, C C个逗号和 P P个句号组成的单词库 ( 1 ≤ P , C ≤ N ≤ 10 3 ) (1≤P,C≤N≤10 3 )。他只能使用单词或标点符号与单词库中的单词或标点符号相同的次数。帮助他输出包含最大可能单词数的句子序列。 每个输入文件包含 T ( 1 ≤ T ≤ 100 ) T(1≤T≤100)个独立的问题实例。 输入格式: 第一行包含T,实例的数量。每个实例的指定方式如下: 第一行包括三个整数, N , C , N,C,和 P . P. 接下来的N行将包含两个字符串。第一个字符串将是农夫约翰可以使用的单词本身(一个包含1到10个小写字母的字符串),而第二个字符串将是以下之一:名词,及物动词,不及物动词或连词,表示该词的类型。同一个单词可能在农夫约翰的单词库中出现多次,但每次它都将具有相同的类型。 输出格式 在第一行,输出最大可能的单词数。 在第二行,输出包含最大可能单词数的任何句子序列。将接受任何有效的序列。 评分程序对空格很敏感,请确保不输出任何额外的空格,特别是在每行的末尾。 样例 输入数据 1 3 1 1 1 bessie noun 10 5 4 bessie noun taught transitive-verb flew intransitive-verb elsie noun farmer noun john noun and conjunction and conjunction nhoj noun mooed intransitive-verb 24 5 4 but conjunction bessie noun taught transitive-verb flew intransitive-verb elsie noun farmer noun john noun and conjunction and conjunction nhoj noun mooed intransitive-verb bob noun impressed transitive-verb cow noun impressed transitive-verb leaped intransitive-verb elsie noun bella noun buttercup noun pushed transitive-verb mooed intransitive-verb envy noun john noun nhoj noun 输出数据 1 0 9 nhoj mooed. farmer taught elsie, bessie and john flew. 23 nhoj mooed. nhoj impressed john, farmer, elsie, bessie and cow impressed bob. bella pushed elsie and buttercup flew. envy mooed but john leaped. For the first test case, the only valid sequence is the empty sequence. For each of the next two test cases, it is possible to construct a sequence of sentences using every word from the word bank except for one. 数据范围与约定 输入2-6: N ≤ 10 N≤10 输入7-11: N ≤ 100 N≤100 输入12-16: N ≤ 1000 N≤1000 余数除以5时为2的输入:没有及物动词。 余数除以5时为3的输入:没有不及物动词。 余数除以5时为4的输入:没有连词。
最新发布
11-15
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值