Skip to content

Learning data structures, algorithms, machine learning and various computer science constructs by programming practice from resources around the web.

License

Notifications You must be signed in to change notification settings

codeAligned/learning-computer-science

 
 

Learning Computer Science

logo

Learning data structures, algorithms, machine learning and various computer science constructs by programming practice from resources around the web.

Requirements

Development Environment

Highly recommended to open/use this repository using Visual Studio Code.

Language Version Package
Java 12 OpenJDK (AdoptOpenJDK with HotSpot)
Python 3.7.2 N/A

Updating VSCode Extensions List

  1. Get json data for list of extensions using the uploaded Sync file in GitHub.
  2. Filter by metadata.publisherId using the website https://jsoneditoronline.org/.
  3. Update list in file .vscode/extensions.json.

Usage

Viewing

Options

  1. Open repository using Visual Studio Code. Recommended extensions have been provided by the repository (.vscode folder).
  2. Use Sourcegraph.
  3. A website for filtering and querying is work-in-progress.

Running Tests

  1. VSCode tasks are available via the repository (.vscode folder) for running all language specific tests. Please familiarize yourself with using tasks in VSCode.

Contributing

  1. Please follow the template for adding problems. This is inherently tied into the mechanism for searching through problems using the planned website.
  2. Templates for metadata.json (problem metadata), readme.md (problem definition) and language specific solution and solution test files are available via VSCode snippets. They are all committed and available via the repository (.vscode folder). Please familiarize yourself with using snippets in VSCode.
  3. You are encouraged to fork this repository and submit pull requests.

Other

  1. For those who may not wish to use VSCode and instead prefer a simple text editor
    1. I plan to create a makefile.
    2. Instructions will be provided at a later time for command line usage to add new problems, run tests, etc. Ref
  2. I do not recommend using any sort of bloated IDE. They tend to add a lot of files simply for their specific plumbing.

Upgrading to newer versions of development environments

Java

  1. Install latest version of Java: OpenJDK (Red Hat for Windows).
  2. On Windows, update the Path environment variable to point to new Java install location. Look out for JAVA_HOME env var, and javapath in the Path env var.
  3. Update build.gradle script (sourceCompatibility and targetCompatibility).
  4. Download and update the (latest) version of gradle compatible with the new version of Java.
  5. In Windows, update the Path environment variable to point to new gradle install location.
  6. In the repository root, from admin command prompt, run gradle wrapper --gradle-version <new gradle version>.
  7. Make sure distributionUrl in gradle/wrapper/gradle-wrapper.properties points to new gradle version.
  8. Delete .project and .classpath files.
  9. Delete all contents of bin directory.
  10. Close VSCode.
  11. Clear workspace cache.
  12. Restart VSCode.
  13. Make sure new .project and .classpath files have been generated. Verify that .classpath now points to the new version of Java. This may take a good few minutes.
  14. Run gradlew test and code coverage tasks.
  15. Update CI scripts (appveyor, circle-ci, travis) to point to new Java version.
    1. For circle-ci, docker image tags can be viewed here.

Gradle

From the project root, run .\gradlew.bat wrapper --gradle-version x.x.x. For Linux, run gradlew from the root, instead of the .bat file. Use the desired version in the command. Verify that the distributionUrl field in the file gradle-wrapper.properties has been updated to reflect the correct version. [Reference]

Python

  1. Install latest version of Python.
  2. Run tasks for python tests, coverage reports and problems list.
  3. Update CI scripts (appveyor, circle-ci, travis) to point to new Python version.

Continuous Integration

Platform Provider Operations Status
Windows, Linux AppVeyor Build, Test Build status
Linux Travis CI Build, Test, Deploy to gh-pages Build Status
Linux Circle CI Build, Test CircleCI
N/A CodeClimate Check for code maintainability Maintainability
N/A CodeClimate Check for test coverage using Circle CI Test Coverage
N/A Codacy Code analysis/quality check Codacy Badge
N/A CodeBeat Static code analysis codebeat badge
N/A Codecov Code coverage using Circle CI codecov
N/A Coveralls Code coverage using Circle CI Coverage Status Known issue
N/A FOSSA Open Source Software Management FOSSA Status work-in-progress
N/A CII Best Practices Open source software best practices check CII Best Practices
N/A david-dm Check node.js dependency status Dependency Status
N/A david-dm Check node.js dev dependency status devDependencies Status

Project Management

GitHub Projects

Links

Sourcegraph

Note

  1. Problems in the repository are not necessarily solved by me. The goal is to learn. Sometimes in the interest of time, that involves understanding an existing solution rather than spending an inordinate amount of time trying to solve it by myself. Where applicable I have provided references to the original solution.
  2. Problems in this repository are not unique. Given that the same (or similar) problem may exist in multiple origins, more than a few problems are repeated. It is my goal to provide some sort of querying mechanism via a website for users to view only a unique instance of a problem, either from a "first or default" origin or a specified origin.

About

Learning data structures, algorithms, machine learning and various computer science constructs by programming practice from resources around the web.

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 94.9%
  • JavaScript 2.4%
  • Python 1.0%
  • HTML 0.5%
  • C# 0.4%
  • TeX 0.4%
  • Other 0.4%