-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Feature Request: Dynamic Resource Addition for Pyramid Calculations
Overview
In the Pyramid Resource Calculation section, the ability to dynamically add new resources (like copper) at runtime could greatly enhance the program's flexibility and usability. This would not only improve code maintainability but also allow future users to easily extend the calculations without needing to modify the existing codebase significantly.
Proposed Implementation
- Dynamic Resource Management: Introduce a data structure (e.g., a dictionary or map) that stores resource names as keys and their associated calculations as values. This will enable adding new resources seamlessly.
- Calculation Logic: Refactor the existing resource calculation methods to accommodate resources defined in the dynamic structure. Implement a method that retrieves the required calculations based on resource names.
- Example Resource Addition: Provide a clear example in the documentation on how a user can add a new resource, such as copper, along with any special calculation rules it might have.
- Testing: Develop unit tests that cover scenarios of adding new resources and ensuring correct calculations.
Benefits
- Scalability: Allows users to add resources without modifying existing code, making the tool adaptable.
- Maintainability: Reduces the risk of errors and simplifies the addition of new calculation types.
This feature would greatly enhance user experience and allow better engagement with ancient Egyptian mathematical challenges. Looking forward to hearing thoughts on this suggestion!
Metadata
Metadata
Assignees
Labels
No labels