Sign in

Software engineer

S SINGLE RESPONSIBILITY

O Open/Closed Principle

L Liskov Substitution

I Interface Segregation

D Dependency Inversion

Main Problems with the SOLID principle solves

Change can be requested anytime and it can break existing code.

Tight Coupling making reusability difficult.

If use the SOLID principle your single change in any file is no effect on other files (class).

Single Responsibility Principle:

A class should have only one reason to change. A class should have only one job.

Ex(x): For software development, we have multiple people doing different things as designers do design, tester do testing and developer do development.

Open for extension/closed…


The Collection is an interface “ Which can be used to represent a group of objects as a single entity whereas “Collections” is an utility class” present in Java. util package to define several utility methods for collection objects.

Collection — — — — — — — — — — — — — — — — — interface.

Collections — — — — — — — — — — — — — — — — — Class.


Comparable(I):

It is meant for default natural sorting order. Present in Java. lang package.

This interface defines only one method compareTo(). All Wrapper classes and String implement a Comparable interface.

public int compareTo(Object obj):

obj1.compareTo(obj2)

returns -ve iff obj1 has to come before obj2.

returns +ve iff obj1 has to come after obj2.

returns 0 iff obj1 & obj2 are equal.

Comparator(I):

It is meant for customized sorting order. Present in Java. util package.

This interface defines two methods compare() and equals(). The only implemented classes of Comparator are Collator and RuleBasedCollator.

public int compare(Object obj1, Object obj2)

returns -ve


image from geeksforgeeks

Creating a new job thread for every job may create a performance on memory problems to overcome this we should go for the thread pool.

Thread pool is a pool of already created threads ready to do our job.

Java 1.5v introduces the Thread pool framework to the implements thread pool.

Thread pool framework is also known as executor framework.

We can create a Thread pool as follows:

ExecuterService service = Executors.newFixedThreadPool(3)

We can submit a runnable job by using submit method

service.submit(job);

We can shut down executors service by using shutdown method

service. shotdown();

import java.util. concurrent.*;

public class…


Git is a version control system of distributed nature that used to track changes in the source code during software development.

It can be used to track any changes in any set of files.

GitHub, on the other hand, is a Git repository hosting service that provides a web-based graphical interface.

It provides task management tools for projects, access control, and collaboration features.


Merging vs Rebasing

The first thing to understand about git rebase is that it solves the same problem as git merge.

Both of these commands are designed to integrate changes from one branch into another branch — they just do it in very different ways.

Consider what happens when we start working on a new feature in a dedicated branch, then another team member updates the master branch with new commits. This results in a committed history.

Now, let’s say that new commits in the master are relevant to the feature that you are working on. …


“Cultivate the habit of being grateful for everything that comes to you, and to give thanks continuously.” Ralph Waldo Emerson

Here are 61 things that I am thankful for today:

  1. I am thankful for my health
  2. I am thankful to have a God who loves me
  3. I am thankful that we have the freedom to worship how and where I want
  4. I am thankful for my “Maa”/ “Pappa”
  5. I am thankful for my home
  6. I am thankful for the freedom of speech
  7. I am thankful for the beautiful sunrise
  8. I am thankful for the amazing sunset
  9. I am thankful for…


Nothing vast enters the life of mortals without a curse.

If you are not paying for the product, you are the product.

Please watch the documentary “ The Social Dilemma” after that you have to a basic idea about what is psychology works behind every social media app.

Thank you! for reading. Stay home and stay safe.

Originally published at https://medium.com on September 27, 2020.

Sudhanshu Jha

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store