Skip to content

stychu/javascript-tasks

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JavaScript Regex

Summary

JS Assessment for JavaScript regex knowledge. The exercise consist of a few simple tasks. You are supposed to implement functions, having provided only the function name and purpose.

Goals

Your solutions should be placed inside app/regex`.js file(inside window.regexAnswers object).

containsNumber(str):

Check if string contain number. Returns true if str contains a number, false otherwise.

containsRepeatingLetter(str):

Detects a repeating letter in a string.

endsWithVowel(str):

Determines whether a string ends with a vowel.

captureThreeNumbers(str):

Captures the first series of three numbers.

matchesPattern(str):

Determines whether a string matches a pattern.

isUSD(str):

Detects correctly-formatted monetary amounts in USD.

Before you start...

JavaScript basic functions:

http://www.w3schools.com/jsref/

Javascript EcmaScript5 tutorials and more:

https://developer.mozilla.org/en-US/docs/Web/JavaScript

Setup

To install dependencies

npm install

JShint

To run verify jshint:

grunt jshint:default

Run tests

To start developing unit tests

grunt test:dev

To run tests and static analysis

npm test

Good luck!

About

JavaScript exercises and tasks for RealSkill

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published