title: How can i drag a moving image using JQuery?
body: <p>Hello i am new to JQuery or java actually i am newbie at programming!!! I did basic tutorial of jQUERY and making a game using Jquery. I am stuck at one thing and also not sure if my code is correct anyway here is my code..</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>var b = function($b, speed) {
      var beeWidth = $b.width();
  
      $b.animate({
          "right": "90%",
          "left": "90%"
      }, speed, function() {
          $b.animate({
              "left": 0 - beeWidth + "px"
          }, speed, function() {
              b($b, speed);
          });
      });
  
  };
  $(function() {
      b($("#b"), 5000);
      b($("#bOne"), 4500);
      b($("#bTwo"), 4000);
      b($("#bThree"), 3500);
      b($("#bfour"), 3000);
      b($("#bfive"), 2500);
      b($("#bsix"), 2000);
      b($("#bseven"), 1500);
  });</code></pre>
  <pre class="snippet-code-css lang-css prettyprint-override"><code>body * {
    display: block;
  }
  body {
      background-image: url("...");
  }
  
  img{
    width: 150px;
    height: 75px;
    position:relative;
    display:inline-grid;
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;script type="text/javascript" src="http://code.jquery.com/jquery-latest.js"&gt;&lt;/script&gt;
  &lt;img id="b" src="http://www.clker.com/cliparts/s/o/o/A/x/F/bee-md.png"&gt;
  &lt;img id="bOne" src="http://www.clker.com/cliparts/s/o/o/A/x/F/bee-md.png"&gt;
  &lt;img id="bTwo" src="http://www.clker.com/cliparts/s/o/o/A/x/F/bee-md.png"&gt;
  &lt;img id="bThree" src="http://www.clker.com/cliparts/s/o/o/A/x/F/bee-md.png"&gt;
  &lt;img id="bfour" src="http://www.clker.com/cliparts/s/o/o/A/x/F/bee-md.png"&gt;
  &lt;img id="bfive" src="http://www.clker.com/cliparts/s/o/o/A/x/F/bee-md.png"&gt;
  &lt;img id="bsix" src="http://www.clker.com/cliparts/s/o/o/A/x/F/bee-md.png"&gt;
  &lt;img id="bseven" src="http://www.clker.com/cliparts/s/o/o/A/x/F/bee-md.png"&gt;</code></pre>
  </div>
  </div>
  </p>