且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

文字处理。删除不以元音开头的单词

更新时间:2023-11-26 18:55:22

是的,在我看来我应该找到一个元音,如果我们之前有空间它是真的,当我们跳过一切都到了其他空间。这个过程是连续的
Yes indeed, in my opinion I should find a vowel and if we have space before it its TRUE, when we skip everything till other space. And this process continuous


一个简单的解决方案是使用包含当前状态的变量作为

A simple solution would be using a variable containing current state as either
  1. 处理一个有效的单词。
  2. 处理空白。
  3. 处理要跳过的单词。



然后,基于当前状态和下一个字符,您的程序可以正确地建立起来。


Then, based on current state and next char, your program could establish correctly what to do.