JDoodle is an online compiler you can embed in your website here we will teach how to integrate an online compiler into your website. 

Using JDoodle compiler you can run your code snippet. It supports many languages like C, C++, Java, python, and almost all programming languages you can learn in a web browser.

Steps to follow 

Step 1: Go to JDoodle.com and sign in, if you don’t have an account then you have to register first. 

Step 2: Select programming language that you wanna use and write your code and save it. Click on editable share and copy the embed URL.

Screen 2

Screen 3

Step 3: On your website page make the div and include JDoodle Javascript CDN file as follows:

Make div in your html with data-pym-src attribute 

  <div data-pym-src="URL Paste From JDoodle"></div>

and bottom of the page insert the JavaScript of jdoodle.

 <script src="https://www.jdoodle.com/assets/jdoodle-pym.min.js" type="text/javascript"></script>

Complete Example:

<!DOCTYPE html>
        <title>Jdoodle Example</title>
       <div data-pym-src="https://www.jdoodle.com/embed/v0/3a1X"></div>
     <script src="https://www.jdoodle.com/assets/jdoodle-pym.min.js" type="text/javascript"></script>