81
Go HTTP Server
Go can be also used to create web applications. Net/http is a library package used to build web applications. It has HandelFunc() function which routes the incoming request to its corresponding function. The ListenAndServe function is used to create a resource server which listens to the provided port. The function someFunc has the http.ResponceWriter and http.Request type parameter. It is responsible to take the incoming request and after processing the return response.
Go http server example
Output:
Next TopicGo Reset Api