Skip to content

Add missing # Note: headers to practice105–practice112 - #250

Merged
Huerte merged 1 commit into
Huerte:mainfrom
tylrcc:docs/notes-105-112
Nov 12, 2026
Merged

Huerte merged 1 commit into
Huerte:mainfrom
tylrcc:docs/notes-105-112

Conversation

@tylrcc

@tylrcc tylrcc commented Nov 12, 2026

Copy link
Copy Markdown
Contributor

For #242 — the files I named in my comment on the issue.

practice105.py through practice112.py in solutions/python/ already had # Problem: and # Source: headers, but no # Note: and no description, so a reader still could not tell what approach each solution takes. This adds exactly one # Note: line to each, written from reading the code:

  • practice105 — greedy halve/subtract-or-add loop for reducing n to 1
  • practice106 — stack applies s's backspaces, result compared with t as entered
  • practice107 — brute force over every pair swap
  • practice108 — maximum checked against twice every other element
  • practice109 — sorted scan for the first gap between neighbours
  • practice110 — set intersection of the two arrays
  • practice111 — brute-force product of all other elements, O(n^2)
  • practice112 — single pass splitting words at uppercase letters

Comments only: the diff is 8 insertions and 0 deletions, and every added line is a comment. I did not change any code, including where a script's approach differs from the canonical solution for its problem (the notes describe what the code in the file actually does). All eight files still compile (py_compile), and I smoke-ran practice110 and practice111 with sample input to confirm unchanged behaviour.

For context: I scanned the whole solutions/python/ folder — every file there already has Problem and Source headers; about 90 files are in the same no-Note state as these eight, so the issue still has plenty of files for other contributors.

@Huerte
Huerte merged commit db98d3f into Huerte:main Nov 12, 2026
1 check failed
@Huerte

Huerte commented Nov 12, 2026

Copy link
Copy Markdown
Owner

@tylrcc Hi there! Thank you for the contribution and for the detailed findings.

download (6)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants