diff --git a/.eslintrc.js b/.eslintrc.js index 27c17f7..3e6aa50 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,3 +1,4 @@ + module.exports = { "extends": "airbnb-base", "rules": { diff --git a/.gitignore b/.gitignore index bb5c8c1..0f67d91 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ + /node_modules .idea \ No newline at end of file diff --git a/README.md b/README.md index 52bbe82..92491b3 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,4 @@ + # Algorithms/services implemented by Feschenko Natalia Instalation: diff --git a/lib/binary-search/binary-search.test.js b/lib/binary-search/binary-search.test.js index 1bfbfab..ec79872 100644 --- a/lib/binary-search/binary-search.test.js +++ b/lib/binary-search/binary-search.test.js @@ -1,3 +1,4 @@ + const should = require('should'); const algo = require('../index.js'); diff --git a/lib/binary-search/index.js b/lib/binary-search/index.js index 406b368..6ea8aff 100644 --- a/lib/binary-search/index.js +++ b/lib/binary-search/index.js @@ -1,3 +1,4 @@ + module.exports = (sequance, el) => { let start = 0; let end = sequance.length - 1; diff --git a/lib/data-structures/queue/index.js b/lib/data-structures/queue/index.js index 1714e1e..2ceef18 100644 --- a/lib/data-structures/queue/index.js +++ b/lib/data-structures/queue/index.js @@ -6,4 +6,6 @@ module.exports = (firstElement, secondElement, findElement) => { findElement = queue.shift(); console.log(findElement); return findElement; -}; \ No newline at end of file +}; + + diff --git a/lib/data-structures/stack/index.js b/lib/data-structures/stack/index.js index f435174..3693a6a 100644 --- a/lib/data-structures/stack/index.js +++ b/lib/data-structures/stack/index.js @@ -1,3 +1,4 @@ + module.exports = (firstElement, secondElement, findElement) => { const stack = []; stack.push(firstElement); diff --git a/lib/dynamic-connectivity/index.js b/lib/dynamic-connectivity/index.js index c0fd9cc..0177c19 100644 --- a/lib/dynamic-connectivity/index.js +++ b/lib/dynamic-connectivity/index.js @@ -33,3 +33,4 @@ module.exports = class { } } }; + diff --git a/lib/index.js b/lib/index.js index ea9836e..dedfb83 100644 --- a/lib/index.js +++ b/lib/index.js @@ -1,3 +1,4 @@ + const binarySearch = require('./binary-search'); const stack = require('./data-structures/stack'); const queue = require('./data-structures/queue'); diff --git a/lib/sorts/binary-heap-sort/binary-heap-sort.test.js b/lib/sorts/binary-heap-sort/binary-heap-sort.test.js index 5410276..f49e53b 100644 --- a/lib/sorts/binary-heap-sort/binary-heap-sort.test.js +++ b/lib/sorts/binary-heap-sort/binary-heap-sort.test.js @@ -1,3 +1,4 @@ + const should = require('should'); const algo = require('../../index.js'); diff --git a/lib/sorts/bubble-sort/bubble-sort.test.js b/lib/sorts/bubble-sort/bubble-sort.test.js index f57afad..bc53944 100644 --- a/lib/sorts/bubble-sort/bubble-sort.test.js +++ b/lib/sorts/bubble-sort/bubble-sort.test.js @@ -1,3 +1,4 @@ + const should = require('should'); const algo = require('../../index.js'); diff --git a/lib/sorts/insertion-sort/index.js b/lib/sorts/insertion-sort/index.js index c2679f9..d61c329 100644 --- a/lib/sorts/insertion-sort/index.js +++ b/lib/sorts/insertion-sort/index.js @@ -1,3 +1,4 @@ + module.exports = function insertionSort(array) { let i; let temp; @@ -12,4 +13,6 @@ module.exports = function insertionSort(array) { array[j] = temp; } return array; + }; + diff --git a/package-lock.json b/package-lock.json index 889c4cd..ff0af36 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,3 +1,4 @@ + { "name": "algorithms-feschenko", "version": "1.0.0", diff --git a/package.json b/package.json index 235060d..514cc59 100644 --- a/package.json +++ b/package.json @@ -1,3 +1,4 @@ + { "name": "algorithms-feschenko", "version": "1.0.0",