Let us start with basic routing. If you are absolute beginner, don’t worry. Just remember, in the ‘app/Http’ folder there is a file called ‘routes.php’ where primarily the ‘request’ and ‘response’ mechanism is settled. We will discuss ‘request’ and ‘response’ architecture in detail later. But as a beginner, to start with you remember that HTTP protocol or grossly web is based on REST architecture and ‘request’ and ‘response’ cycle is the essence of the whole thing. When we say this, it is bit simplified but we will come back to this point once again.

We would like to advance our primary knowledge. We want to make some output. So forget everything and concentrate on the ‘routes.php’ file. When your application is launched, the ‘routes.php’ file looks something like this:
//code starting
Route::get('/', function () {
return view('welcome');
//code ended
Here 'Route' is a class that has a static method 'get' that returned a 'view' method which presents a page. When a user visits the home page he is taken to the 'welcome' page. Look at the code, there is an anonymous function also.