N-tier is the best approach to develop an application. N-Tier Application is divided in multiple applications like client application and server application). In this one application get interact with another application.
For developers, it is easy to make the change in application which developed with N-Tier approach, because user could directly go to source code of Client side or Server side.
Figure 1: Client side or Server side
In the above figure, we saw client side application and server side application whose code has been written separately . If a user would like to make some UI changes, then without disturbing the server he/she could update but if N-tier application is not there, then it will not be so easy as N-Tier approach has.
Also client side application could divide in multiple numbers and it will interact with the business logic code then business logic code will interact with the data access layer. Point to remember is that GUI directly could not interact with Data access layer. This application will be a 3 tier application as in the following figure:
Figure 2: 3-Tier application
Above shown 3-tier application could be developed in 4-tier application in which there will be separate Business Logic code for each and every GUI application.
Here's a figure for 4-tier application:
Figure 3: 4-Tier application
As in the above figure, the GUI is divided in number application and each and every application interacting with separate business logic code. The GUI is interacting with common business logic code and business logic code is interacting with Data access layer.
Recap: One application divide in Multiple Application and one application interact with another application to give the output. These are known as N-Tier application. In N-Tier, the application interact with Data access, but GUI does not interact directly with Data access.
Also we can tell one layer interact with another layer is known as N-Tier In general it contains 3 layers: Presentation layer, Business logic code layer and Data access layer. Presentation Layer contains code for only GUI, business logic code layer contain only business logic code and data access layer contain only data access code. Presentation layer interact with Business Logic code layer and Business logic code layer interact with Data Access layer. Presentation layer directly could not interact with Data access layer.