##Overview
This project contains only two searching functions. They are
- linear Search :
It is a generic type function. This function will take two arguments, Array and value to search in that array. It returns an object which contains two properties position and comparisons.
- binary Search :
It is a generic type function. This function will take two arguments, Array and value to search in that array. It doesn't returns anything. It prints value position in the console itself.
##How to use it :
Run the command "npm i typescript-searching-methods" in the command prompt. It will be downloaded into node modules folder in your Project.
1)Now attach searching-functions.d.ts file path in the typescript file where you want to use these searching methods.
for example : /// or import * from "typescrtipt-searching-methods";
- Attach searching-functions.js file in your main html file.
for example:
<script src="../../typescrtipt-searching-methods/dist/lib/searching-functions.js"/></script>