title: python read file and output into format string
body: <p>I have a sample json file example below</p>
  <pre><code>    {
        &quot;email&quot;: &quot;string&quot;,
        &quot;cont_pic&quot;: &quot;string&quot;,
        &quot;title&quot;: &quot;string&quot;,
        &quot;user_cd&quot;: &quot;string&quot;,
        &quot;type4&quot;: &quot;string&quot;
      }
  </code></pre>
  <p>and want to convert into a formatted string like example below  , it will convert into public static XX= 'yy';<br />
  Where XX is the Upper case of yy</p>
  <pre><code>  public static EMAIL= 'email';
    public static CONTACT_PIC = 'cont_pic';
    public static TITLE = 'title';
    public static USER_CODE = 'user_cd';
    public static TYPE4 = 'type4';
  </code></pre>
  <p>I have stuck at below code</p>
  <pre><code>filename = &quot;file.json&quot;
  with open(filename) as f:
      contents = f.read()
      contents = contents.split(':')
      print(contents)
  </code></pre>