Giter Site home page Giter Site logo

edsomjr / competitive-problems-tools Goto Github PK

View Code? Open in Web Editor NEW
8.0 7.0 7.0 9.09 MB

Competitive problems formatter tools

License: GNU General Public License v3.0

C++ 95.58% Makefile 0.14% Shell 3.68% C 0.18% Java 0.01% Python 0.01% TeX 0.35% Roff 0.06%

competitive-problems-tools's Introduction

cp-tools

Competitive programming Tools Logo

About the projectInstallationFeaturesBasic usageTestsTechnologies


About

Format, test and pack competitive programming problems.

Installation

Clone this project and build with command make:

$ make

To install cp-tools, use the command below as a super user:

$ make install

The binary will be copied in /usr/local/bin. The support files will be copied in /usr/local/lib/cp-tools directory.

To uninstall run

$ make uninstall

Dependencies

  • pdflatex
  • GCC 10
  • Python 3
  • libssl-dev
  • clang-format (optional)

Features

  • Generates the problem PDF and checks the solutions
  • Integration with Polygon
  • Integration with MOJ
  • Support for interactive questions

Basic usage

To create a basic problem template use the following command on an empty directory:

$ cp-tools init

To remove auto-generated files (which are located in .cp-build folder in current directory), use the command

$ cp-tools clean

To generate the PDF version of the problem, use the command

$ cp-tools genpdf

The command

$ cp-tools check

verifies the validator (flag -v), the checker (flag -c) or the tests (flag -t).

To judge a solution, use the command

$ cp-tools judge solution[.c|.cpp|.java|.py]

To connect to Polygon API use the command

$ cp-tools polygon

For more information, use the option -h (or --help), as shown below:

$ cp-tools -h

Or read cp-tools man page using

$ man cp-tools

Tests

To run the unit test use the commands

$ make
$ ./cp-run_tests

Polygon connection tests

On a local run of the tests you need to set both environment variables: POLYGON_KEY and POLYGON_SECRET.

If you are using Travis on your own fork you must add the environment variables POLYGON_KEY and POLYGON_SECRET following the official tutorial.

Technologies

  • C++20
  • GCC v.10.3.0
  • LaTeX

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.