Skip to content

Latest commit

 

History

History
17 lines (14 loc) · 808 Bytes

File metadata and controls

17 lines (14 loc) · 808 Bytes

Competitive programming templates

All templates target Java 17 and intentionally use no package declaration. Copy the smallest useful file into a problem folder, then keep Main as the entry-point class required by most judges.

Area Contents
java/boilerplate Fast input, buffered output, and a contest-ready Main
java/data_structures Fenwick tree / binary indexed tree
java/graphs Dijkstra for non-negative weighted graphs
java/math Modular exponentiation and inverse helpers
java/range_queries Iterative segment tree for range sums
java/strings Prefix function and KMP search

The algorithm files are snippets: paste the class into your Main.java and adapt indexing, identity values, and numeric types to the problem constraints.