title: How to put DOUBLE with decimal place to JSONObject? ex:- 34.0
body: <p>using JSONObject to send to web service when we put double (round number) the zero and the point gets removed</p>
  <pre><code>    JSONObject ctx = new JSONObject();
      try {
          ctx.put(&quot;csrf&quot;, vfModel.getCsrf());
          ctx.put(&quot;vid&quot;, vid);
          ctx.put(&quot;ns&quot;, &quot;&quot;);
          ctx.putOpt(&quot;ver&quot;,BigDecimal.valueOf(34.0));
          
         } catch (JSONException e) {
          e.printStackTrace();
          Log.e(TAG, &quot;JSONException null generateToken: &quot; + e.getMessage());
      }
  </code></pre>
  <p>Output</p>
  <pre><code>{&quot;csrf&quot;:&quot;VmpFPSxNakF5TVMwd01pMHhNbFF4TXpveE16b3pNaTQ1TkRSYSwwVUVJT3kycmh6SGRYY01EZ1BWR1I3LE0yTmtaV1V6&quot;,&quot;vid&quot;:&quot;06690000005lUNp&quot;,&quot;ns&quot;:&quot;&quot;,&quot;ver&quot;:34}
       
  </code></pre>