Strategy design pattern
A strategy pattern is a behavioral design pattern that allows the behavior of an object to be selected at runtime.
public interface TripStrategy {
void travel();
}
public class LongTripStrategy implements TripStrategy{
@Override
public...
gurupalaniveltech.hashnode.dev1 min read