Category Archives: Week-14

The Importance of Clean Code: Striking the Right Balance

Clean code is an important aspect of a software developer’s skill set. It means writing code that works well, and is easy to read, understand, and maintain. Three key principles of writing clean code are conciseness, reusability, and a clear flow of execution. Each principle in its own way contributes to the ease with which the software development process proceeds and the reliability of the end product.

1. Striking the Right Balance Between Conciseness and Clarity:

Finding the right balance between writing concise and clear code is very important. Concise code can make the codebase easier to read and it reduces the amount of time spent writing it. However, being too concise can make the code difficult to understand. The goal is to keep the code brief but also easy to read and understand without losing its purpose or logic.

2. Reusability

Another important principle of clean code is reusability. Writing code that can be reused in different parts of an application or across different projects saves time and reduces redundancy. Reusable code leads to a more modular structure, which makes the codebase easier to maintain and enhances its flexibility. It not only speeds up development but also makes it easier to fix bugs and make future updates.

3. Explicit Flow of Execution

A clear flow of execution is one of the critical characteristics of the code that guarantees its readability and ease of maintenance. A not well structured code leads to a condition where it is difficult to maintain a project. A logical and straightforward flow of code is easy to perceive by a developer, which is necessary for the code support during the whole life cycle.

4. The Single Responsibility Principle (SRP)

Every module or class should have only one responsibility. This decreases complexity, thereby making the code base manageable. Testing  and debugging, with development and improvements for future maintenance, are all greatly simplified, hence, the software becomes easier to use and much more understandable.

Conclusion

The balance between conciseness, reusability, clear execution, and following the Single Responsibility Principle will definitely allow developers to write clean code, benefiting the whole process of software development. Clean code is not simply error avoidance, but also it improves collaboration inside the team, makes life easier for new developers, and significantly increases the speed of code reviews. This will definitely result in efficient, maintainable software with easy adaptation to changes. Keeping these principles in mind allows me and other peers to create software that is functional, yet high quality and user-friendly. Even though we have done Clean code in Software process management class, reading this article helps as a reminder for writing code as best possible and also comes with examples which I did not include not to make this blog post too lengthy, but I suggest everyone to go and read it.

Citations:

https://www.freecodecamp.org/news/how-to-write-clean-code/

From the blog CS@Worcester – Maria Delia by Maria Delia and used with permission of the author. All other rights reserved by the author.

Git

Version control is a vital component of modern software design and git is the most popular version control system. Git is essential. It allows you to safely experiment, track changes, and it creates an organized workflow for something that can become chaotic fast. In this blog post, I will be going over some Git basics and some practical uses of git.

Git tracks changes in your code. This allows you to be able to go back to any version of your code and restore it if need be. This also allows you to see who’s done what work. this can help keep people accountable. Multiple people are also able to work at the same time without overwriting each other’s work. This makes collaboration much easier. Branching and merging allow anyone to be able to work with anyone whether they are in the same room or across the globe. Git also can allow you to experiment with your code. Branches allow you to manipulate and test code, without touching the source main code.

Basic git commands

Saving in git is called committing. If you commit you save the current state of all your files and folders. you would use git commit -m “message” This message should be a description of the changes made in this commit.

git clone is used to clone your current repository

git add is going to tell git that I would like to add this file as one to track the next time I make a commit.

Using the git add and git commit commands in conjunction allows you to only save/commit specific files.

Git status will tell you what is currently happening in your repository. You use this to help find where you are in git.

Git push sends the changes made up to Git Hub. This compresses all the information and sends it up to Git Hub.

git pull is the opposite of git pull. This allows you to bring the latest version of the project to your workspace.

Forking allows you to create a copy of someone else’s repository onto your own account.

Merge conflicts: this happens when changes coming from different locations conflict.

The Video I used as a source Is an amazing resource. It takes all the basic concepts of git and boils it down in a very simple and effective manner. It also shows examples of everything being used and talked about in a practical setting. I am a visual learner so I found this extremely helpful. The video is 50 minutes long, but if you are able to, you can watch this in 25 minutes at 2x speed with captions. I recommend anyone who is interested in git to watch this video. Even if you are experienced, it is an amazing refresher and I will be using it to study git concepts for this class alongside our material. I watched this video before attempting a git-related homework assignment and it felt like I was using git differently. I felt confident when using the commands. Before there was much more trial and error and I second-guessed myself a lot. Although the resource I chose doesn’t have much new information, I found it extremely helpful and encouraged anyone taking software processes management to check out this video.

Referance: https://www.youtube.com/watch?v=NcoBAfJ6l2Q&t=15s

tags: Week-14 , CS@Worcester, CS-343

From the blog CS@Worcester – SPM blog by Aaron Nano and used with permission of the author. All other rights reserved by the author.

What is Vue and Why is it Popular?

Link to blog: https://medium.com/js-dojo/how-is-vue-js-making-the-javascript-world-a-better-place-b3dc39ba4fe7

It’s the end of the semester, and the last thing we covered in class was a bit of front-end structure and how things work. Of course, there’s your HTML and CSS, and I understood that. But we were using Vue in our examples, and I got curious. I’ve heard of Vue before but never used it, so I was interested in its purpose. Such curiosity led me to Fotis Adamakis’ blog post How is Vue.js making the Javascript world a better place. We’ll be discussing the contents of this article today.

Adamakis’ blog post is quite in-depth compared to past articles we have covered. He believes Vue is quite beginner-friendly, as learning how it works and beginning to write code could only take a couple of days to a week (as long as you have some knowledge of Javascript, HTML, and CSS). Adamakis dives into some interesting parts about Javascript frameworks and how Vue approaches them.

Routing can be a potential challenge when it comes to tasks such as custom scroll behavior, nested route view mapping, and more. Vue has its own Router, and it configures the routes before any components are rendered. 

Vue’s approach to the architecture of a site supports component-building. To be more efficient, it includes single-file components. This is a beneficial feature of Vue, as it can contain HTML, CSS, and Javascript all in a single file. Adamakis also mentions Vue’s high satisfaction rating, with the majority of developers wanting to use it again! 

Adamakis mentions that Vue is great for testing too, as it has built-in support for Mocha and Jest unit testing or end-to-end testing with Cypress or Nightwatch. 

Adamakis concludes by stating that he feels Vue has combined all great parts of other Javascript frameworks into one, being easy to use with great documentation.

I selected this resource because it educates me more on why Vue is so popular and what it does well. It also has example videos to highlight the reasons and is well-written and easy to understand.

I found this to be a solid article for learning more about Vue and why it’s preferred. I also learned how Vue’s state management works. It’s interesting that with Vue, you can incorporate HTML, CSS, and Javascript into a single file. Perhaps it’s beneficial for the simplicity or organization of different web pages/parts of a page? Having all of the pieces of a component on one file is probably quite helpful. I hope to apply this to new web pages I might try and build (I would like to get more into building websites!).

From the blog CS@Worcester – Josh's Coding Journey by joshuafife and used with permission of the author. All other rights reserved by the author.

A New Belt, A New Perspective

This week I chose to read “The White Belt” section under “Emptying the Cup”. This pattern calls for one to fully embrace the beginner mindset when faced with new learning opportunities. It encourages placing preconceived ways of thinking aside when tackling new situations to do so with a clean slate to allow for new perspectives to be formed. By subscribing to this mindset, one can increase their learning and understanding of different languages which in turn will aid them to progress their path as a craftsman forward.

This pattern highlights the importance of learning in professional growth because, in today’s rapidly evolving market, the ability to adapt and learn new skills is crucial for staying relevant and competitive prospects. Reaching a certain level of expertise may cause one to fall into complacency or build a reluctance to venture into unfamiliar territory.

What I find insightful about this pattern is its analogy to martial arts, where the white belt symbolizes a beginner’s journey toward mastery. Just as a martial artist must approach each new technique with a fresh perspective, a software craftsman must be willing to let go of their preconceptions and embrace the unknown. This pattern serves to remind readers that mastery is not a destination but a continuous journey of growth and self-improvement.

The pattern also highlights the discomfort that can accompany stepping outside of one’s comfort zone, especially for experienced craftsmen. As someone who takes pride in their expertise, it can be challenging to admit ignorance or make mistakes. However, the quote from George Leonard reminds us that embracing foolishness and spontaneity is often the key to unlocking creativity and innovation.

I appreciate the advice provided in the pattern, such as unlearning something familiar or exploring new programming paradigms. This encourages craftsmen to actively seek out opportunities for growth and challenge themselves to expand their horizons.

While I agree with the overall premise of “The White Belt,” I recognize that fully embracing a beginner’s mindset requires courage. It’s not easy to admit when we don’t know something or to let go of our old ways of thinking. However, as the pattern suggests, the benefits of adopting this mindset far outweigh the temporary discomfort one may feel.

In conclusion, this pattern serves as a powerful reminder of the importance of courage, curiosity, and continuous learning in the development of one’s craft. By embracing a beginner’s mindset, craftsmen can unlock new possibilities, foster innovation, and ultimately reach greater levels of mastery in their chosen fields.

From the blog CS@Worcester – Eli's Corner of the Internet by Eli and used with permission of the author. All other rights reserved by the author.

Retreat into Competence

Retreat into competence is a pattern that involves taking a break from a challenging task to work on something you are more comfortable or confident in. This helps a developer reflect on how far they have come and can keep them motivated to move forward. Patterns may emerge that show how you got proficient in that task. These patterns can then be used to advance your current tasks. Motivation can also be a problem if someone is constantly getting stuck on a task, or just not being able to progress a project forward. Being able to step back and complete a more familiar task can help keep up the drive during the long road.

This pattern really popped out at me originally for the “Context” and “Problem” sections, as I have felt very overwhelmed many times finishing up my college degree. There have been countless times that I have questioned if I have learned enough for my degree. Each semester felt like it only introduced me to a whole new branch of computer science that I didn’t know. Even the classes that had focused on more advanced topics still felt like it was only just the tip of the iceberg.

There have been a few times this semester that I have been stuck on an issue and just could not figure out where to start looking for a solution. It can be really demotivating when you are unable to complete a task that other people are relying on you to complete. Taking the time to work on another issue helped me in both ways mentioned above. Solving an issue that I was confident I could do made me realize what steps I needed to follow to work on the other issue. Not only this, but being able to actually complete an issue kept my motivation up as I felt like I was contributing to the team.

When I first read through this pattern I originally thought mostly about the motivation and satisfaction aspects of being able to complete a task that is familiar to you. However, as I read through it and began to understand more about what you could learn from working on more approachable projects. Paying attention to and understanding the patterns and steps one takes to solve familiar problems can be used to solve new or challenging issues.

From the blog CS@Worcester – CS Learning by kbourassa18 and used with permission of the author. All other rights reserved by the author.

CS-448: Week 14

Retreat into Competence

This pattern is about how it is easy to get caught up in constantly learning new technologies due to the fast pace of software development, and how to manage the intense pace of learning. The pattern highlights the importance of taking a step back from the fast paced learning and to focus on honing existing skills. Trying to learn the latest tools, frameworks, and methodologies can be overwhelming. Along with the overwhelming feeling of trying to learn many skills at once, there is also a risk of never fully mastering the fundamentals. Therefore it is important to take a step back, and take time to practice fundamental skills.

According to the pattern, being an apprentice is a rollercoaster ride. This is because there is the thrill using newly learned skills to deliver value to the customer, but there is also the terror of realizing how little is known compared to more experienced craftsman and experts. However both are normal and inevitable experiences.

Although the pattern encourages developers to take a break from learning new skills, it also emphasizes how retreating back to competence is to not get stuck in the realm of competence. It is important to be intentional when retreating, as this pattern is only a short term fix. Spending too much time on this pattern can lead to halted learning. Being able to learn something new is a skill in itself; therefore, learning should be practiced unlike any other skill.

In order to prevent the pattern being used, setting a time limit for honing new skills is useful. This is so one does not focus too much on retreating, and helps them stay in the habit of learning new skills. A strategy the pattern suggests is to pick a well understood topic that is self contained, and to reimplement it. This can help regain confidence to propel learning.

Conclusion

I found this pattern to be interesting as constantly learning new technologies can be tiring, so having a strategy to regain confidence is helpful for the future. I particularly enjoyed the analogy of a catapult to represent this pattern. The analogy being that the skill of learning new topics can be launched forward by taking a step back. The pattern has changed the way I view learning new skills, and maintaining old ones.

From the blog CS@Worcester – Zack's CS Blog by ztram1 and used with permission of the author. All other rights reserved by the author.

CS448 Software Development Capstone – Apprenticeship Patterns – “Confront Your Ignorance”

For my final Apprenticeship Patterns reflection, I want to talk about the “Confront Your Ignorance” pattern in the second chapter, “Emptying the Cup”. In the last sprint of our software development capstone course, I felt that I wasn’t able to deliver my best work – partly because of how undeveloped my unit testing design skills are, and partly because I caught a mild cold partway into the sprint that zapped my energy levels. If I want to be honest though, the former problem was the more severe of the two, and it will stick around far longer than the sniffles I had. I’ve realized how much more I need to study the technologies I’ve been working with. In combination with the “Reading List” and “Record What You Learn” patterns, I want to put this pattern into action over the summer break and establish a disciplined reading and studying habit for software development topics.

In addition to the unit test design, there were other parts of the work I took part in over the semester that I didn’t completely understand before it came time to implement them. Docker is one subject I want to take the time to research in further detail, since it was an essential component of our work. I first encountered Docker last semester, but it wasn’t until this semester that I’ve understood what the purpose and benefits of virtualized containers are. I know now that Docker allows development teams to create applications within a common virtual operating system. What I want to learn more about is how to write docker-compose files to initialize a functional HTTP backend server. One of my tasks this sprint was to do just that for one of the backend microservices in Thea’s Pantry, and I wouldn’t have been able to do that if there wasn’t a complete docker-compose file in another backend that I could adapt for the repository I was working in.

The largest gap that in my knowledge that I’ve been wanting to address is my technical skill with Java. Java has been the language that I’ve accomplished the most with, next to Python, but I haven’t taken the time to write any Java this semester besides the foundations of my MonsterFactory project, which I realize now could qualify as an example of the “Breakable Toys” pattern from the textbook. Over the summer I think I would like to implement my studying of unit test design into the MonsterFactory and create some tests for the abstract factory classes.

From the blog CS@Worcester – Michael's Programming Blog by mikesprogrammingblog and used with permission of the author. All other rights reserved by the author.

Unlocking Success Through Understanding Failure

Throughout the long road of lifes, we always strive to find success, but sometimes we may hit roadblocks and fail. Some of us choose to accept those failures and learn from them, but others may neglect those failures and choose to take an alternative route. The Learn How You Fail pattern, emphasizes the importance of embracing failure. Embracing failure is a crucial aspect of not only personal growth but also professional growth. This pattern encourages us to look for our weaknesses and patterns of failure, and instead of avoiding them, accepting and learning from them. If we can gain knowledge on how, why, and what led to our previous failures, we can learn from them, make adjustments, and pave a path to success in the future.

When we think of the word failure, we often think that it carries a negative connotation, referencing setbacks or disappointments. Yet, in our journey as aspiring craftsmen, failure is not just part of our professional learning, it is possibly one of our greatest teachers. We’ve all experienced some sort of failure at some point in our lives. But the most important part of dealing with failure is pinpointing why we failed, fixing it, and taking those issues head on.

I found this pattern to be extremely interesting considering many people give up after they fail. Failure isn’t something that should be feared or avoided. Instead it should be embraced as a catalyst for learning and self development. It underscores the idea that true growth comes from a willingness to confront our failures and adapt. What I find particularly interesting about this pattern though, is its emphasis on self-awareness and introspection. By actively seeking to understand our patterns of failure, we can empower ourselves to make better decisions about our personal and professional development.

After reading more, I was able to connect the pattern to the software development field. In the field, we cannot just expect to find success. Through lots of learning, practice, and trial and error, we can eventually find success. Instead of viewing failure as a setback or embarrassment, I view it more as an opportunity for reflection and growth. I now realize the importance of acknowledging my successes but also embracing my failures as learning experiences. In the future, I plan on having a more proactive approach towards identifying and addressing any of my weaknesses, rather than just ignoring them.

With this being said, the Learn How You Fail pattern, offers valuable insights into the importance of embracing failure as a means of personal and professional development. By learning from our failures, we can ultimately find success in our chosen fields.

From the blog CS@Worcester – Conner Moniz Blog by connermoniz1 and used with permission of the author. All other rights reserved by the author.

Embrace Growth: Be the Lion’s Tail Instead of the Fox’s Head

Summary of the Pattern:

In the pursuit of professional growth, stagnation can often be a hindrance. The pattern, “Be the Worst,” advocates for seeking out environments where one is the weakest member of the team. By intentionally placing oneself in a position where there’s ample room for learning and improvement, individuals can continue to progress in their careers.

Reaction to the Pattern:

“Be the Worst” challenges conventional wisdom by advocating for humility and a willingness to learn from those more skilled. Initially unreasonable, this approach fosters an environment conducive to continuous learning and development. The personal narrative of David H. Hoover underscores the transformative power of embracing this pattern, highlighting the significant gains that can be achieved by putting oneself in a team of exceptional developers.

Interesting Insights:

The notion of deliberately positioning oneself as the weakest member of a team prompts reflection on personal growth and professional aspirations. It underscores the importance of humility and the recognition that true progress often stems from embracing challenges rather than seeking comfort in familiarity.

Impact on Professional Perspective:

For individuals navigating the dynamic landscape of their profession, “Be the Worst” prompts a re-evaluation of traditional career trajectories. It encourages a shift from a mindset focused solely on achieving positions of authority to one centered on continuous improvement and skill acquisition. This pattern has the potential to redefine how individuals approach their careers, emphasizing the value of learning and adaptability in an ever-evolving industry.

Disagreements and Considerations:

While “Be the Worst” advocates for joining teams where one is the least skilled, it’s essential to acknowledge potential challenges. The risk of feeling overwhelmed or inadequate may deter some individuals from fully embracing this pattern. Moreover, the pattern’s emphasis on humility and learning from others may not align with certain cultural norms that prioritize individual achievement over collaborative growth.

In conclusion:

“Be the Worst” serves as a reminder of the transformative power of humility and the value of surrounding oneself with mentors and peers who inspire growth. By embracing the discomfort of being the least skilled team member, individuals can unlock unparalleled opportunities for learning and advancement in their professional journey.

From the blog CS@Worcester – Site Title by rkaranja1002 and used with permission of the author. All other rights reserved by the author.

CS-448 Week 14 Breakable Toys

The “Breakable Toys” pattern offers a solution to a common problem faced by software developers, which is the lack of opportunities to learn from failure in a professional setting. The purpose of this pattern is to create a safe environment where developers can experiment, make mistakes, and learn without fear of repercussions. By building toy systems that mimic real-world settings but with reduced scope and complexity, developers can gain valuable experience and develop their skills more effectively.

The intriguing thing about this pattern is its emphasis on the importance of failure in the learning process. In many industries, including software development, there’s often a stigma attached to failure, which leads to a culture where taking risks is discouraged. However, this pattern changes that mindset by suggesting that failure is not only acceptable but also a necessary step toward growth and improvement.

As someone whose goal is to become a software developer, this pattern has certainly changed my perspective on my approach toward learning and skill development. It highlights the value of creating a learning environment that prioritizes experimentation and iteration over perfection. This helps get rid of the fear of failing and being afraid to make mistakes, and now I see them more as opportunities to grow and learn.

One of the aspects of the pattern that resonates with me is the idea of “budgeting for failure”. By allocating time and resources to build and experiment with breakable toys, developers can proactively invest in their own professional development. This proactive approach to learning is essential in this industry due to the continued growth and evolution, where adaptability and continuous improvement are key to success.

While I do like this style of thinking, I can also see potential challenges in implementing this pattern in a corporate environment that may prioritize productivity and efficiency over learning and experimentation. Convincing management or team leaders of the benefits of breakable toys may require a shift in mindset and a willingness to embrace a culture of learning and innovation.

Overall, the Breakable Toys pattern offers a refreshing perspective on how to approach learning and skill development in software development. By creating a safe space for experimentation and failure, developers can cultivate a growth mindset and become more resilient and adaptable in the face of challenges.

5. Perpetual Learning | Apprenticeship Patterns (oreilly.com)

From the blog CS@Worcester – Jason Lee Computer Science Blog by jlee3811 and used with permission of the author. All other rights reserved by the author.