Overview
Quick Test CLI supports seven popular programming languages used in competitive programming. The tool automatically detects the language based on file extensions and handles compilation and execution appropriately.Supported languages
C++
GNU C++17 with competitive programming flags
Python
Python 3 interpreter
Java
Java Development Kit
C
GNU GCC C11 compiler
Rust
Rust with popular competitive programming crates
Go
Go programming language
Kotlin
Kotlin JVM compiler
C++
File extensions
Language details
- Standard: C++17
- Compiler: g++ (GNU C++ Compiler)
- Special flags:
-DONLINE_JUDGE=1is automatically added
Compilation and execution
- Unix/Linux/macOS
- Windows
Compilation:Execution:
The
-DONLINE_JUDGE=1 flag allows you to use conditional compilation in your code:Python
File extensions
Language details
- Version: Python 3
- Interpreter: python (or python3 depending on system configuration)
Execution
Python is an interpreted language, so no compilation step is required. Quick Test CLI runs your script directly.
Java
File extensions
Language details
- Compiler: javac
- Runtime: java
- Note: Your main class must match your filename
Compilation and execution
- Unix/Linux/macOS
- Windows
Compilation:Execution:
C
File extensions
Language details
- Standard: GNU C11
- Compiler: gcc (GNU C Compiler)
- Math library: Automatically linked with
-lm
Compilation and execution
- Unix/Linux/macOS
- Windows
Compilation:Execution:
The
-lm flag links the math library, allowing you to use functions from <math.h> without additional configuration.Rust
File extensions
Language details
- Build tool: cargo
- Edition: 2021
- Pre-installed crates: proconio, num, rand, regex, num-bigint
Compilation and execution
- Unix/Linux/macOS
- Windows
Compilation:Execution:
Available dependencies
Quick Test CLI automatically configures a Rust project at~/.quicktest/rust/ with these dependencies:
Using Rust dependencies in your code
Using Rust dependencies in your code
Quick Test CLI initializes the Rust environment on first use. Subsequent compilations reuse the existing project for faster build times.
Go
File extensions
Language details
- Compiler: go
- Build mode: Executable binary
Compilation and execution
- Unix/Linux/macOS
- Windows
Compilation:Execution:
Quick Test CLI copies your Go file to
~/.quicktest/go_mod/ before building to ensure a clean build environment.Kotlin
File extensions
Language details
- Compiler: kotlinc
- Runtime: java
- Output format: JAR file with runtime included
Compilation and execution
- Unix/Linux/macOS
- Windows
Compilation:Execution:
The
-include-runtime flag bundles the Kotlin runtime with your compiled code, making the JAR file self-contained.Language detection
Quick Test CLI automatically detects the programming language based on file extensions. You don’t need to specify the language explicitly.Extension detection
The tool reads the file extension from your target file, correct file, generator file, or checker file.
Language mapping
The extension is mapped to one of the supported languages using the internal configuration.
Command selection
The appropriate compilation and execution commands are selected based on the detected language and operating system.
Customizing compilation
You can customize C++ compilation settings using thesetup command:
Prerequisites
Before using Quick Test CLI, ensure you have the necessary compilers and interpreters installed:Installation check
Installation check
Quick Test CLI verifies that the required compiler/interpreter is installed before running tests. If a tool is missing, you’ll see an error message with installation instructions.You can manually check if a language is available:
Next steps
Test modes
Learn about the different test modes available
Getting started
Install Quick Test CLI on your system