This code puzzle is implemented using ASP.NET Core 2.1.
Because I am not yet proficient with jQuery and Angular, I implemented this code puzzle using MVC and post form. I have just started to learn Angular. So, I guess I need a few days to implement this task using Angular.
Also, I implemented API method for future consumption using front-end frameworks. Example of API request: http://localhost:8888/api/ShapeGenerator/Draw%20an%20octagon%20with%20a%20side%20length%20of%20100