--- title: I before E except after C id: 5a23c84252665b21eecc7eb0 challengeType: 5 videoUrl: '' localeTitle: 我在E之前除了C之后 --- ## Description
短语“我在E之前,除了C之后”是一个广为人知的助记符,它应该有助于拼写英语单词。使用提供的单词,检查短语的两个子句是否合理:
  1. “我在E之前没有前面的C”。
  2. “在我之前的C之前是C”。
如果两个子短语都是合理的,则原始短语可以说是合理的。编写一个接受单词的函数,并检查单词是否遵循此规则。如果该函数遵循规则,则该函数应返回true,否则返回false。
## Instructions
## Tests
```yml tests: - text: IBeforeExceptC应该是一个函数。 testString: 'assert(typeof IBeforeExceptC=="function","IBeforeExceptC should be a function.");' - text: IBeforeExceptC("receive")应该返回一个布尔值。 testString: 'assert(typeof IBeforeExceptC("receive")=="boolean","IBeforeExceptC("receive") should return a boolean.");' - text: IBeforeExceptC("receive")应该返回true 。 testString: 'assert.equal(IBeforeExceptC("receive"),true,"IBeforeExceptC("receive") should return true.");' - text: IBeforeExceptC("science")应该返回false 。 testString: 'assert.equal(IBeforeExceptC("science"),false,"IBeforeExceptC("science") should return false.");' - text: IBeforeExceptC("imperceivable")应该返回true 。 testString: 'assert.equal(IBeforeExceptC("imperceivable"),true,"IBeforeExceptC("imperceivable") should return true.");' - text: IBeforeExceptC("inconceivable")应该返回true 。 testString: 'assert.equal(IBeforeExceptC("inconceivable"),true,"IBeforeExceptC("inconceivable") should return true.");' - text: IBeforeExceptC("insufficient")应返回false 。 testString: 'assert.equal(IBeforeExceptC("insufficient"),false,"IBeforeExceptC("insufficient") should return false.");' - text: IBeforeExceptC("omniscient")应该返回false 。 testString: 'assert.equal(IBeforeExceptC("omniscient"),false,"IBeforeExceptC("omniscient") should return false.");' ```
## Challenge Seed
```js function IBeforeExceptC (word) { // Good luck! } ```
## Solution
```js // solution required ```