Skip to content

Latest commit

 

History

History
49 lines (35 loc) · 2.04 KB

File metadata and controls

49 lines (35 loc) · 2.04 KB

AGENTS.md

Languages & tooling

  • Java: JDK 24, no Maven/Gradle. IntelliJ compiles to out/. No CLI build.
  • Python: Poetry (pyproject.toml), Python ^3.9. Dev deps: black, pylint, isort.
  • JavaScript: Node 14, no package.json. Run directly.

Tests

No test framework exists. Run files directly:

  • Java: Open in IntelliJ, run the Test* class with main() at the bottom of the same file.
  • Python: poetry run python <file> — scripts use if __name__ == "__main__":.
  • JS: node <file>.

Commands

Action Command
Install Python deps poetry install
Export requirements.txt make req_txt (runs poetry export -f requirements.txt --output requirements.txt)
Run any Python file poetry run python src/main/algo/sort/merge/merge_sort.py
Run any JS file node src/main/algo/search/binary/binary_search.js

Formatting & linting (Python only)

  • Formatter: black (88 char line width). Runs on save via VS Code.
  • Import sort: isort with profile = "black". Runs on save via VS Code (source.organizeImports).
  • Linter: pylint, enabled in VS Code.
  • Config split between pyproject.toml (isort) and .vscode/settings.json (black, pylint).

Java conventions

  • No generics, no exceptions (documented as TODOs in source).
  • Uses primitive int arrays throughout.
  • Each data structure class includes a package-private Test* class with main() at the bottom of the file.

Structure

  • src/main/ — DSA implementations (algo/ds/maths/benchmarks).
  • src/questions/ — practice problems sorted by platform (codesignal/, leetcode/).
  • src/playground/ — scratch directory, git-ignored.
  • Benchmarks in src/main/benchmarks/ use load.py helpers (load_numbers(), load_strings()).

Python environment

  • VS Code interpreter hardcoded to ~/.pyenv/versions/dsa-practice/bin/python (machine-specific — won't work elsewhere).
  • Project name in pyproject.toml is dsa.
  • requirements.txt is auto-generated by make req_txt; do not edit manually.