Category Archives: Week 4

Week of October 2, 2023

https://refactoring.guru/design-patterns/singleton

This week, I wanted to a find a source relating to software design and architectures. I’ve been curious about what I would need to know so I could write more robust and efficient code. One aspect of improving my code would be knowing how best to preserve available system memory and perform whatever tasks I need to within as few CPU cycles as I can. If my program is creating multiple instances of a class that are all doing the same thing, my code would be consuming more system resources than if I had one instance of a class that could be accessed by other parts of my code. The Singleton design pattern seeks to preserve memory consumption by utilizing a single static instance of a class that may be globally referenced from the rest of the program. To properly implement the Singleton, the constructor for your Singleton instance should be static and private. To get the instance, you would also need a public static creation method.

My homework for this week involves refactoring a class into the Singleton pattern, so I was especially interested in learning about it. I found this blog called The Refactoring Guru, and a post explaining the implementation of the Singleton, as well as the pros and cons from a design perspective. The Singleton design is useful when a program needs global access to a class, like when a program has a single attached database. The drawbacks of the Singleton approach, though, are that it does too many things at once in violation of the Single Responsibility Principle, and that it may compromise your program’s security because of a crucial class being accessed as a global variable.

The final paragraph of the blog post makes some comparisons between the Singleton design and two other software design patterns, Façade and Flyweight. Façade is a design pattern of constructing a simple user interface with a complicated backend. This design pattern offers a sort of “black box” functionality to users, having a simple frontend to interact with without the need to inform users about the inner implementations of the software. The practical example given for a Façade software design is a video encoding service that accepts video files from the user as input and returns the same file encoded in a new file format. The user would only need to interact with the function that accepts a file and a desired file type as parameters, without needing to access the methods within the program that perform operations on the input file.

This blog includes helpful illustrations and pseudocode to explain multiple different software design patterns. I’ve been needing more resources on broader software structure and design rather than individual blocks of code, and I’m happy that I found this website.

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.

Cs-348, Cs @ Worcester Week 4

Software Development Methodologies

This week we have learned about software development methodology which is a series of processes used in projects. It is a codified communication tool which is a series of workflows between a group of people about how they are going to work, pass information, and communicate between each member in certain ways.

There are two methodologies that were introduced in our class. Waterfall software development methodology is one where each step is performed in order, a single time, and each step is not started until the previous step is completed. Agile methodology, one of the features of this software development methodology is that the cycle of steps is performed repeatedly, in short increments.

I found a blog that points out the common methodologies and they conclude with a comparison between them and also give out suggestions that might suit certain projects.

URL link: https://intersog.com/blog/top-software-development-methodologies/

  1. Waterfall
    This is the most straightforward approach to software development; however, it is relatively rigid as it consists of sequential phases that follow one another in order. All of these stages are performed in sequential order, the next step is started after the previous one is over.
    This method is essential to have clear objectives and stable project requirements. The main disadvantage is rather rigid and does not allow for any flexibility. Once the development stage is over, it is hard to come back to it and implement any changes. Another issue with this method is that it takes a long time.
  2. Agile
    Agile is an alternative development methodology that offers an entirely different experience from the Waterfall model. The idea is to break the development process down into bite-size pieces, increments, allowing the developers to make fast gradual changes to create a perfect end product.
    The agile method has the advantage of enabling developers to make incremental progress over a limited number of iterations. If any adjustments are required, they may always go back to a prior milestone. This method is appropriate for tasks when the final product’s appearance is uncertain. This approach, however, places an undue emphasis on team communication that may be difficult for remote teams to manage. Additionally, the project manager must have extensive experience in managing the entire project.
  3. Rapid Development
    The purpose of this method is to repeat the user design and construction phase as often as needed to satisfy the client’s requirements. This method could produce great results faster and at a lower cost. Being a popular alternative to agile in software development, it allows the developers to adjust to the changing requirements to meet the needs of a changing market.
    So, as much as agile, this approach suits dynamic projects in volatile markets and allows for rapid changes at a low cost. However, RAD method needs to ensure the developers’ expertise.
  4. Lean

This method cuts all the redundancies and inefficiencies to maximize performance. Maximizing the output of the project and the individual contributors. Professional software development teams already use a Lean approach, it is most effective when combined with another method, any project can be made Lean by reducing waste and emphasizing top-priority tasks. It needs a team of developers who can suit their approach to customer demands.

  1. Feature-Driven Development
    The large projects requiring months and months of backend coding, implementing the Feature-Driven Development (FDD) model might work for these projects. Usually, each feature takes a couple of weeks to finish its steps, and by the end of the development cycle, you get yourself a fully functional end product.
    This model is suitable for large projects, and remote teams as it requires fewer client and vendor meetings. The model requires a strong understanding of the project’s scope from every individual developer – all of them need to know what they are working towards.

To sum up, we must choose the one that suits your project. However, they prefer Agile as the most used approach that fits most projects and allows for greater flexibility, especially regarding long-term development cycles. This blog helped me to understand the process of each methodology and know the way to find a suitable method for the project in the future.

From the blog CS@Worcester – Hong Huynh-CS348-WSU by hhuynh3 and used with permission of the author. All other rights reserved by the author.

What is Git?

For the entirety of this course so far we have been working and getting familiar with the version control tool git. In this week’s blog I will be writing about a blog called “What is Git | Explore a Distributed Version Control Tool” by Reshma Ahmed. I have chosen this article in particular to see how it came to existence, the roles they play in companies, and to get a further understanding in addition to what we have learned in class.

From the article I have learned the different types of version control such as centralized version control system and distributed version control systems. Git was created in 2005 by Linus Torvalds designed to “handle small to large projects with efficiency”. Git is a distributive version control system which is a system that prevents corruption and crashes that were caused from having a server hosted in a single repository such as in centralized version control systems due to everyone having a copy on their machine of their local repository. When reflecting back to the course we have been practicing with pushing and pulling from repositories, branches, as well as removing and adding commits. The GitKit activities worked on in class shown us practical issues that one may face with git such as merging issues as well as issues involving different versions of commits.

The article describes some of the features of git which we have looked at in class such as being open source as well as being secure. Open source software encourages transparency, collaboration, and accessibility similar to the FOSS communities mentioned in the first GitKit activity done in class. The article reads “Git uses the SHA1 to name and identify objects within its repository”. This concept becomes apparent from seeing in the GitKit activities done in class when applying commands such as “git log” that shows a commits’ hash as well as the date a commit was made.

Git not only is used in the software development community but plays a detrimental role in companies with more and more companies using git as their go-to version control system. Some of these companies include tech giants such as “Facebook, Yahoo, Twitter, eBay, Salesforce, [and] Microsoft” which shows the significance of git.

When reflecting for my personal future use of git, practical applications of git in the field of machine learning and data science is using git to manage datasets to ensure reproducibility as well as data integrity. In addition, I plan on using git for my data mining course project when collaborating with other peers.

Links

https://www.edureka.co/blog/what-is-git/#companies_using_git

From the blog CS@Worcester – Anthony Duong CS Blog by anthony duong and used with permission of the author. All other rights reserved by the author.

osu!lazer

Osu! is a free rhythm game that I often play and keep up with. Developed by Dean “peppy” Herbert, it was released in 2007 and was heavily inspired by a 2005 Japanese rhythm game known as Osu! Tatakae! Ouendan. The game, even to today, is not very popular compared to what is considered the “mainstream” for video games; but the players and fans of it are truly dedicated and supporting. Since its release, peppy sought to improve, fix, and maintain the game but that became increasingly difficult with how old and jumbled the code for the game was; and thus, he decided to work from the ground up. In 2015, he began the development of an osu! 2.0 which soon became known as “osu!lazer.” 

I chose to cover this game because the development is public, its updates are being covered on their youtube channel, and I enjoy the game and its community. While watching this video (a bunch of lazer updates), I noticed that a well known player known as -GN made a pull request. It was at this point in which I realized that they’ve been working on GitHub and that what they do is basically what I’ve been learning but in a real-world application. 

I thought that now that I was a little more familiar with GitHub and the process of development, I could check out what was happening with osu!lazer. I went to their repository page (https://github.com/ppy/osu/releases) and simply looked around. The most notable things about the repo would be the number of issues and pull requests. 1,000 active issues is already quite the number but over 25,000 issues over the course of this project seems simply insane. This may just be due to my lack of knowledge and experience as this is a relatively small team and project but those numbers could be even bigger with much larger games and their possibly massive development teams. 

Exploring the repo made me realize how complicated software development, game development, or any other kind of development can be, at least with my current knowledge and experience. For example, there are lots of tags used for issues and pull requests, areas of the game, priority, and size are just some of the categories that the team has decided to divide the development into. I realized that how the game is developed, in the coding, more technical, and specific aspects is still quite foreign to me. Despite having taken computer science classes for many years and creating code in those classes, this level of programming seems so far away. I hope to be able to get to this level and possibly even contribute to osu!lazer, but I occasionally find myself questioning if I’ll really be able to code at this level. 

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

Don’t Repeat Yourself!

When it comes to writing code, the one thing you want to keep an eye on is that you’re not using the same line of code you used on multiple projects. The don’t repeat yourself principle also known as the DRY principle aims to solve problems is knowledge of duplication. This idea is applied through all levels and phases of software development, most of the time it’s used while making classes. When making classes you end up implementing the same logic in multiple parts of the code. A solution is to remove the common functionality and only implement the parts that are different.

Another example of repeating yourself happens while you’re storing data. You start to create unnecessary attributes in your table, usually, you can derive those attributes from other attributes since they’re mutually dependent on each other. The problem with duplication is that things can change and once you make one change you have to change all of its representations. Making changes requires analysis, In other words not making any proper changes will lead to opposite representations of the same knowledge. These duplicates can happen in multiple ways someone could make a mistake while making the design, and a strict deadline can make people feel rushed to meet that deadline.

DRY is a principle and there are three methods to implement that principle. First is abstractions which are commonly used when making classes, when multiple classes are shared and come with common logic you simply want to abstract the logic into a superclass that each class inherits. The standard object-oriented program has a lot of practices that encourage the DRY principle for writing reusable, readable, and maintainable code. Second automation is a project case for developers. It’s to make sure that developers are communicating with each other so they don’t repeat finished work and talk about any problems they’re having. Last is normalization, this case is for designing databases. Repetition is common in a lot of data representation but creates redundant data, which is hard to maintain. You would want to extract the cases into a separate entity then the source references that entity. The goal is to ensure that the data is consistent and distributed correctly. Data normalization removes repetition in data, making the database more flexible. 

The reason why I picked this topic is because I tend to repeat myself a lot thinking that it wouldn’t be too much of a problem for me to end up having problems with my code and making my code a little more confusing. By using this principle and using the three methods it helps me make sure that my code is readable, reusable, and easy to maintain. I feel like this principle is important to use for everybody who is making a code by themselves or as a group.

Sources: https://www.plutora.com/blog/understanding-the-dry-dont-repeat-yourself-principle

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

CS@Worcester – Zack's CS Blog 2023-10-04 12:20:04

Week 4: Understanding Software Licenses

This week I will be writing about software licensing and why I chose this topic. I chose to write about software licensing because I personally do not have much prior knowledge about the topic, so I thought that this would be an interesting (and useful) topic to learn about.

To start off, what is a software license? A software license is a legally binding contract between the software creators and the people who are using the software. The license specifies the conditions of using the software including how the user can use, modify, and distribute the technology and its source code.

Upon initial software usage, the end user usually signs an end-user licensing agreement, or EULA, to contractually agree to the terms stated by the license. Abiding by the EULA is important for both the end user and the developer.

Benefits for the developer:

Benefits for the user:

  • Protects the developer’s rights
  • Allows full control of the usage of the software
  • Prevents users from performing undesired actions that may infringe on the terms of the license
  • Clarifies how the software provider uses your private information
  • Prevents the user from paying for unnecessary tools
  • Keeps the user up-to-date on how the technology can be used

Different Types of Software Licenses (5)

  • Public Domain – Allows anyone to use, modify, and distribute the software. The developers are essentially surrendering all rights they would have under copyright laws.
  • Copyleft (Restrictive) – A type of open-source license stating that any future versions of the software must be open-source, or following the same copyright stipulations, like the source code.
  • GNU Lesser General Public License (LGPL) – A weaker type of Copyleft where the user can modify the software, implement it into their own unique software, and license their software how they see fit.
  • Permissive – Another type of open-source license, minimal amount of restrictions on what users can do with the software. However developers can protect their intellectual property by specifying some restrictions.
  • Propriety – The most strict type for users, and the most protective towards developers. Users are not allowed to modify, copy, or distribute the software. Most used for commercial software.

The resource used was chosen because it was relatively short, yet concise by clearly explaining the basics to understanding software licensing. After reading this blog, I learned a lot as I did not know much about the major types of software licenses and that there are specific licenses that fall under each major type. Therefore the article had a positive impact on me. Because my career goal is to become a software developer, understanding what and how software licenses work will be crucial throughout my entire developer journey. I expect to apply the concepts learned in not only my professional career, but also in my personal life as an end user.

Resources:

Galano, Fernando. “Understanding Software Licensing.” BairesDev Blog: Insights on Software Development & Tech Talent, 22 Mar. 2022, http://www.bairesdev.com/blog/understanding-software-licensing/. 

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.

The Importance of Building Concrete Skills

Being able to build a set of skills that could be one day used by a team of craftsmen is crucial when walking into any profession. Although it’s a little hard for anyone to go into a job that requires one to know a set of skills. It should be clear-cut on the application. But I do agree on attempting to get assimilated on those skills whenever possible because in some cases, these employers want to be able to rely on the fact that you won’t be a liability to the workflow. This goes for a lot of jobs once again. I used to work a construction job when I was 17-18 years old, it was when I wasn’t so sure if I wanted to pursue a career in software craftmanship and I already had a lot of knowledge in the construction trade, four years of knowledge to be exact. The man who acts as a “master” figure to me told me that competence is everything in the professional world, and having little competence is better than having no competence.

It’s also important to expand the competence because it could expand one’s reputation of being a good craftsman for other employers to look at. I would also like to add that being able to work on the skills that one might lack is also important to expand one’s value to the team. Interviewers or hiring managers want to be able to understand your worth in a company, being able to list off certain tasks that can be done to an issue is invaluable, and being able to apply the knowledge that one has is more important. From experience, it also helps to have an experience that proves that you have the concrete skill, no days it’s not enough for employers to see that you know a certificate or course that you might have taken.

It’s more important for the employer to recognize that you have applied the skill set to other, similar jobs or projects. This pattern is a very general one that will be brought up countless times in apprentice’s come-up but, non the less it’s a very important pattern that can be applied to more than just software craftsmanship.

Sources:

Hoover, Dave H., and Adewale Oshineye. Apprenticeship Patterns: Guidance for the Aspiring Software Craftsman. O’Reilly, 2010.

From the blog CS@Worcester – FindKelvin by Kelvin Nina and used with permission of the author. All other rights reserved by the author.

week-4

 Hello, here is a blog post for the fourth week; I feel stressed and relaxed simultaneously because the beginning of March is winding down for enjoyable activities and nearby spring break.

Now that I have reached the end of chapter 3, I will turn my attention to chapter 4, which discusses apprenticeship models. Throughout my reading, I found a pattern that could prove highly useful; I named it “Find Mentors.” I like this pattern because it starts with becoming a software craftsman; you first need to find mentors. You can do this by enrolling in a training course or teaching yourself independently.

This pattern is one of my favorites because it has a “recommend” option. This pattern appeals to me because it includes a “recommend” option that assists someone who needs direction and assists in making better decisions for entering the tech field or interested-related tech. This helps someone who needs advice and assists in making better decisions for entering the tech field or interested-related tech.

Nevertheless, there are some aspects of the practice that I can’t entirely agree with because there isn’t a lot of information or because it’s uncommon for somebody who needs or can’t have a mentor or guidance because there are a lot of different reasons or options when there is additional time. I like to express my disagreement with these aspects of the pattern in the following way: I could not find and have any mentors. After all, it was covid because it affects people’s attitudes, and they needed to focus on themselves rather than trying to predict what would happen next.

Have you noticed that the way you think about the work you want to do in the future or the career path you want to take as a whole has changed due to the practice?

This practice pushed me to think more about expanding my network connections to get more experience and work alongside people in the same field. For suggested action in finding mentors by signing up for an active mailing list, lurk, and seek outpatient teachers for informal advice at the next conference.

From the blog Andrew Lam’s little blog by Andrew Lam and used with permission of the author. All other rights reserved by the author.

week-4

 Hello, here is a blog post for the fourth week; I feel stressed and relaxed simultaneously because the beginning of March is winding down for enjoyable activities and nearby spring break.

Now that I have reached the end of chapter 3, I will turn my attention to chapter 4, which discusses apprenticeship models. Throughout my reading, I found a pattern that could prove highly useful; I named it “Find Mentors.” I like this pattern because it starts with becoming a software craftsman; you first need to find mentors. You can do this by enrolling in a training course or teaching yourself independently.

This pattern is one of my favorites because it has a “recommend” option. This pattern appeals to me because it includes a “recommend” option that assists someone who needs direction and assists in making better decisions for entering the tech field or interested-related tech. This helps someone who needs advice and assists in making better decisions for entering the tech field or interested-related tech.

Nevertheless, there are some aspects of the practice that I can’t entirely agree with because there isn’t a lot of information or because it’s uncommon for somebody who needs or can’t have a mentor or guidance because there are a lot of different reasons or options when there is additional time. I like to express my disagreement with these aspects of the pattern in the following way: I could not find and have any mentors. After all, it was covid because it affects people’s attitudes, and they needed to focus on themselves rather than trying to predict what would happen next.

Have you noticed that the way you think about the work you want to do in the future or the career path you want to take as a whole has changed due to the practice?

This practice pushed me to think more about expanding my network connections to get more experience and work alongside people in the same field. For suggested action in finding mentors by signing up for an active mailing list, lurk, and seek outpatient teachers for informal advice at the next conference.

From the blog Andrew Lam’s little blog by Andrew Lam and used with permission of the author. All other rights reserved by the author.

week-4

 Hello, here is a blog post for the fourth week; I feel stressed and relaxed simultaneously because the beginning of March is winding down for enjoyable activities and nearby spring break.

Now that I have reached the end of chapter 3, I will turn my attention to chapter 4, which discusses apprenticeship models. Throughout my reading, I found a pattern that could prove highly useful; I named it “Find Mentors.” I like this pattern because it starts with becoming a software craftsman; you first need to find mentors. You can do this by enrolling in a training course or teaching yourself independently.

This pattern is one of my favorites because it has a “recommend” option. This pattern appeals to me because it includes a “recommend” option that assists someone who needs direction and assists in making better decisions for entering the tech field or interested-related tech. This helps someone who needs advice and assists in making better decisions for entering the tech field or interested-related tech.

Nevertheless, there are some aspects of the practice that I can’t entirely agree with because there isn’t a lot of information or because it’s uncommon for somebody who needs or can’t have a mentor or guidance because there are a lot of different reasons or options when there is additional time. I like to express my disagreement with these aspects of the pattern in the following way: I could not find and have any mentors. After all, it was covid because it affects people’s attitudes, and they needed to focus on themselves rather than trying to predict what would happen next.

Have you noticed that the way you think about the work you want to do in the future or the career path you want to take as a whole has changed due to the practice?

This practice pushed me to think more about expanding my network connections to get more experience and work alongside people in the same field. For suggested action in finding mentors by signing up for an active mailing list, lurk, and seek outpatient teachers for informal advice at the next conference.

From the blog Andrew Lam’s little blog by Andrew Lam and used with permission of the author. All other rights reserved by the author.