def readJsonFile(fname):
    """Reads data from file using the JSON format. 

   :param fname: file name
   :type fname: string
   :returns: data 
   :rtype: dict/list

   :Example:

   >>> from westpy import * 
   >>> data = readJsonFile("mass.json") 

   .. note:: The file will be read from the current directory. 
   """
    import json
    with open(fname, 'r') as file:
        data = json.load(file)
        print('')
        print('File read : ', fname)
    return data
