Competitive Programming

ICPC 2019

All 11 ICPC problems from 2019, each with a statement view, editorial, and C++ implementation.

11 problem pages
11 statement text files
11 statement PDFs
May 21, 2026 most recently updated solution

Problem set

Each entry below goes straight to the public problem page, with the statement, editorial, code, and raw resources kept together.

ICPC 2019

A. Azulejos

A

Ceramic artists Maria and João are opening a small azulejo store in Porto. Azule- jos are the beautiful ceramic tiles for which Portugal is famous. Maria and João want to create an attractive window display, but, due to limited space in their shop, they mus...

TeX C++ Statement text Statement PDF
Open problem page
ICPC 2019

B. Beautiful Bridges

B

What connects us all? Well, it is often bridges. Since an- cient times, people have been building bridges for roads, for trains, for pedestrians, and as aqueducts to transport water. It is humanity’s way of not taking inconvenient geography for an answer. T...

TeX C++ Statement text Statement PDF
Open problem page
ICPC 2019

C. Checks Post Facto

C

Your university’s board game club just hosted a Checkers tournament, and you were assigned to take notes on the games. Unfortunately, while walking home, you dropped all of your papers into a puddle! Disaster! Much of what you wrote is now unreadable; all y...

TeX C++ Statement text Statement PDF
Open problem page
ICPC 2019

D. Circular DNA

D

You have an internship with a bioinformatics research group studying DNA. A single strand of DNA consists of many genes, which fall into different categories called gene types. Gene types are delimited by specific nucleotide sequences known as gene markers....

TeX C++ Statement text Statement PDF
Open problem page
ICPC 2019

E. Dead-End Detector

E

The council of your home town has decided to improve road sign placement, especially for dead ends. They have given you a road map, and you must determine where to put up signs to mark the dead ends. They want you to use as few signs as possible. The road m...

TeX C++ Statement text Statement PDF
Open problem page
ICPC 2019

F. Directing Rainfall

F

Porto and the nearby Douro Valley are famous for producing port wine. Wine lovers from all over the world come here to enjoy this sweet wine where it is made. The International Consortium of Port Connoisseurs (ICPC) is organizing tours to the vineyards that...

TeX C++ Statement text Statement PDF
Open problem page
ICPC 2019

G. First of Her Name

G

In the Royal Family, names are very important! As the Royal Historian you have been charged with analyzing the patterns in the names of the Royal Ladies in the realm. There have been n Royal Ladies, for convenience numbered from 1 to n. The name of each Lad...

TeX C++ Statement text Statement PDF
Open problem page
ICPC 2019

H. Hobson’s Trains

H

Mr. Hobson has retired from running a stable and has invested in a more modern form of transport, trains. He has built a rail network with n stations. However, he has retained his commitment to free the passenger from the burden of too many choices: from ea...

TeX C++ Statement text Statement PDF
Open problem page
ICPC 2019

I. Karel the Robot

I

Did you know that the word “robot” is almost 100 years old? It was first introduced in 1920, in the science-fiction theatrical play R.U.R., written by Karel Čapek. As a tribute to this Czech writer, an educational programming language was named Karel many...

TeX C++ Statement text Statement PDF
Open problem page
ICPC 2019

J. Miniature Golf

J

A group of friends has just played a round of miniature golf. Miniature golf courses consist of a number of holes. Each player takes a turn to play each hole by hitting a ball repeatedly until it drops into the hole. A player’s score on that hole is the num...

TeX C++ Statement text Statement PDF
Open problem page
ICPC 2019

K. Traffic Blights

K

Cars! Where do they come from? Where do they go? Nobody knows. They appear where roads have been built, as if out of nowhere. Some say that no two cars are alike. Some say that if you look closely, you can see the pale ghosts of miserable humans inside them...

TeX C++ Statement text Statement PDF
Open problem page