This pull request adds a new evenOrOdd function in the Bit Manipulation folder to check if a number is even or odd using bitwise operations. It includes error handling for wrong inputs and test cases to make sure it works properly. This addition improves our JavaScript algorithms collection! #2340
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Continuous Integration | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
jobs: | |
build: | |
name: Code style and tests | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 22 | |
cache: npm | |
- name: 📦 Install dependencies | |
run: npm ci | |
- name: 🧪 Run all tests | |
run: npm run test | |
- name: 💄 Code style | |
run: npm run check-style | |
codespell: | |
name: Check for spelling errors | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: codespell-project/actions-codespell@master | |
with: | |
# file types to ignore | |
skip: "*.json,*.yml,DIRECTORY.md" | |
ignore_words_list: "ba,esy,yse,falsy" |