Giter Club home page Giter Club logo

cs.11.04-quiz.4.1's Introduction

CS.11.04-Quiz.4.1

Declare all methods as static.

  1. Write a method called numberOfVowels.

    Given a string, numberOfVowels will return the number of vowels in that string. Consider a, e, i, o, u as vowels.

  2. Write a method called notDivisibleBy235*.

    Given a number N, notDivisibleBy235 will return the number of natural numbers not exceeding N that are not divisible by any of the numbers [2, 3, 5].

Example

Let's see what happens when N=5:

1 - not divisible by 2, 3, or 5
2 - divisible by 2
3 - divisible by 3
4 - divisible by 2
5 - divisible by 5

Answer: 1 (Of all the numbers from 1 to 5 inclusive, there is one number that isn't divisible by any of 2, 3, 5)

  1. Write a method called camelCaseMe.

    Given a string, this method converts dash/underscore delimited words into camel casing. The first word within the output should be capitalized only if the original word was capitalized (known as Upper Camel Case, also often referred to as Pascal case). The next words should always be capitalized.

Examples

"the-stealth-warrior" gets converted to "theStealthWarrior"

"The_Stealth_Warrior" gets converted to "TheStealthWarrior"

"The_Stealth-Warrior" gets converted to "TheStealthWarrior"

cs.11.04-quiz.4.1's People

Contributors

c-simon-tam avatar techarenz avatar

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.