Hello Everyone!
Tasks for the first two days of Week 12 were oriented on Hash Maps, Sets, and String Manipulations. Today I had a nice workout because today’s challenges are oriented on working with structured data and problems based on symmetry and string transformation. It was a satisfying beginning, since it intertwined logical approach and measurement.
How the Day Unfolded
-
This category would involve equal row and column pairs; that is, the degree of difficulty of this category would be medium.
Describe how many pairs of rows and of columns are equal in a grid.- The Strategy: Constructed a hash map to preserver frequencies of rows which are represented as tuples. Transposed columns into tuples and counted whether the number of matching pairs was in the hash map.
- The Fun Part: When threading patterns in the grid that are symmetrical made me feel like I was solving a puzzle!
-
*Step 3 of 19 – Medium Level – Removing Stars From a String
– Replace characters in a string with modifications according to rules of operator ‘’, which deletes the prior character.- The Strategy: .");
Part 5: Include the following lines in your submission
[Millen’s research study] => [Sears’ textual research study]
The following textual research study was conducted by Sears:
[Millen’s research study] => [Sears’ textual research study]
- The Fun Part: It was gratifying to watch the string change on the fly as stars subtracted characters – it felt like watching an item of text being modified in real life.
Parts of Today
Patterns and Symmetry:
Interestingly, the previously proposed grid-based logic in Equal Row and Column Pairs emphasized the beauty of looking for patterns and studying the ways to make use of the symmetrical approaches in the analyzing of structured data.-
Stack Dynamics:
- Removing Stars From a String explained that special simple string operations might be actually performed using stacks.
Data Structures in Action:
Both problems, hash maps and stacks, highlighted the role of selecting correct data forms to solve problems.
Key Takeaways
Hash Maps for Symmetry:
Some problems like Equal Row and Column Pairs demonstrate how hash maps are used for keeping and searching for a set of structured data that corresponds to the pattern.Stacks Simplify Reversals and Edits:
– The use of stacks in handling reversals and dynamic sequential modifications was illustrated in **Removing Stars From a String”.Break Problems into Logical Steps:
In both the tasks, rigid sequential work flow was adopted because it helps in being very clear and precise in the – >(specification and) implementation–> of tasks.
Reflections
The Equal Row and Column Pairs problem was a fun problem in looking for pattern and dealing with symmetry part and Removing Stars From a String was a reminder of how powerful stack based solution are in handling dynamic changes. In aggregate, these tasks highlighted the need to integrate principles of solving problems and properly structured data.
What’s Next?
The next day I will concentrate on Stack Problems, solving Decode String problem and Asteroid Collision problem. The above tasks will be hard tasks to solve since they concern nested processes and sequential processes.
Well there you have it folks thank you for reading along this week! Well then let’s continue to solve, learn and progress as a society.
Top comments (0)