Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Normalize commutative operations

Open
#40 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
35/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Stale
Tech stack
clojure
Domain
tooling

Research direction

The issue identifies commutative normalization as the target and names =, +, and multi-arity function bodies; start by locating the representer's existing normalization logic and its handling of these forms. Define a deterministic standard order and verify that equivalent permutations produce one representation while preserving the same student-facing feedback.

Written by the indexing model from the issue text.

Description

It never ceases to amaze me how many unique solution approaches there are even with all the normalizations we're doing. It's like ice cream flavors. 31 flavors sounds like a lot, but that can be achieved with like 5 or 6 basic flavors and their permutations.

After spending some time analyzing its results, the next "low-hanging fruit" seems to be:

Identifying which operations are commutative, and presenting them in some standard order.

At first glance it seems like we're scraping the bottom of the barrel, so to speak. But because of the way the possible permutations are composed, even the smallest thing can drastically reduce the number of unique representations, which practically translates to having fewer approaches to add feedback to to be displayed to the same number of students.

For example, a solution to the lasagna exercise might have: (+ (num-layers 2) 5), and another might have (+ 5 (num-layers 2)). Having to repeat the same feedback on every combination becomes tedious.

Commutative operations which can be normalized

  • =
  • +
  • multi-arity function bodies
    . . .

Again, these seem very minor, but the path to making the representer more effective lies in making these incremental improvements

Dominant language
Clojure
Stars
2
Forks
7
Avg merge
8m
Merged PRs (30d)
1

Getting set up

  • Ships a Dockerfile or Docker Compose file
  • No pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from exercism/clojure-representer

All issues in exercism/clojure-representer

Similar issues

More Clojure issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.