Programming & AI Tips πŸ’‘
45.9K subscribers
67 photos
11 videos
30 files
388 links
Programming & AI:
Tips πŸ’‘
Articles πŸ“•
AI & LLMs πŸ‘Ύ
Design, Architecture, Principles βœ…

πŸ‡³πŸ‡± Contact: @MoienTajik
Download Telegram
Class definition πŸ“

The name of a class should describe what responsibilities it does .

In fact, naming is probably the first way of helping determine class size.

If we cannot derive a concise name for a class, then it’s likely too large.

The more ambiguous the class name, the more likely it has too many responsibilities.

#CleanCode #Class
Classes Should Be Small ❗️

The first rule of classes is that they should be small .

The second rule of classes is that they should be smaller than that .

Our immediate question is always β€œHow small❓ ”

With functions we measured size by counting physical lines .

With classes we use a different measure .

We count responsibilities .

#Cleancode #Class