Refuse a judge case above a stated upper bound

Abierto
#856 1 comentario 0 reacciones 1 asignado Ver en GitHub

Los mantenedores suelen responder en 1 día

@Patriciaath999 ya está trabajando en esto.

Desde el 26/11/2026.

Evaluación

Dificultad
3/5
Tiempo estimado
Medio día
Aptitud para principiantes
65/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
rust
Área
backend

Línea de trabajo

Start from check_judge_case_bounds, added for #732 in #829, and the LOWER_BOUND matcher it uses. Add the mirror-image check that reads the maximum from the same constraint forms (plain integers, 10^4, 3 * 10^4), skips any other form, and refuses a judge case above it with the same message shape. Done means a case above the stated maximum is refused, and constraints with unparseable maximums are passed through unchanged.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

check_judge_case_bounds (added for #732 in #829) refuses a judge case below the lower bound a constraint states, but not one above its upper bound. The argument is the same: the interviewer gives the bound when asked, and a candidate told "n is between 1 and 8" may size a C buffer as char out[8][17], or a Java boolean[301] for a template of at most 300 letters, and then fail a case past the stated maximum.

In the review of #829, 148 of the 157 constraints LOWER_BOUND matches were counted as ending in a numeric maximum (8, 5000, 3 * 10^4), with no judge case exceeding any of them, so refusing size > highest would refuse nothing in the bank today and keep it that way.

Proposed: read the maximum of the same constraint forms (10^4, 3 * 10^4 and plain integers), refuse a case above it with the same message shape, and skip a maximum written any other way, as the lower bound does.

Lenguaje dominante
Rust
Estrellas
236
Forks
153
Merge medio
1 d 9 h
PR fusionados (30 d)
187

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de sysprog21/codetrial

Todos los issues de sysprog21/codetrial

Issues similares

Más issues de Rust

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.