Automation has played a significant role in many domains, and stock market trading is not an exception. Even retail traders can automate his/her trading strategy using API. A computer program doing trading is known as Algorithmic Trading. It eliminates inefficiency due to human emotions. Trading logic that decides when to buy and sell a stock is generally term as a trading strategy. The availability of large trading data has made it possible to automate the generation of dynamic trading strategies. Speed and accuracy are very vital aspects of profitable stock market trading. Algorithmic trading is far superior to manual trading in terms of speed and accuracy. In this tutorial, we demonstrate the automation of predefined trading strategies using Python API. We will also demonstrate the generation of trading strategies using Reinforcement learning, Deep learning, and various other domains in computer science. Validating the performance of any predefined trading strategy on historical data plays a significant role in its live performance and it is known as backtesting. Backtesting is the key feature of Algorithmic Trading. We will demonstrate backtesting of the trading strategies using a computer program on the Indian and American stock market data.