Giter Site home page Giter Site logo

java-basic-exercise's Introduction

注意

在GrammarExercise中编写实现代码

确保src/test下的GrammarExerciseTest通过

要求:

  • 分别输入两串由逗号分隔的单词串 eg: apple,juice,mother,people,beautiful,apple,dog cat,baby,smile,good,apple,beautiful,dog,nice 找出两组单词串**同包含的单词(不区分大小写),将单词串按字母顺序排序,去掉重复单词 输出。

输出要求:

  • 找出两组单词串**同包含的单词(不区分大小写),将单词串按字母顺序排序,去掉重复单词 输出。

异常情况:

  • 如果字符串中出现非字母或者连续逗号,则抛出运行时异常,异常信息:input not valid

代码要求:

  • 单词数组的处理用stream而非for循环

特殊情况示例:

  • 输入: apple,juice,mother,people,beautiful,app&le,dog Cat,baby,smile,good,app&le,beautiful,dog,nice 抛出异常: RuntimeException

WARNING

该代码库版权归ThoughtWorks所有。

java-basic-exercise's People

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.