#!/usr/bin/env python # -*- coding: utf-8 -*- # utilisations de elements.py & molmass.py # source : http://www.lfd.uci.edu/~gohlke/ # mars 2020 : adaptation python 3 from molmass import ELEMENTS len(ELEMENTS) str(ELEMENTS[109]) ele = ELEMENTS['C'] print(ele.number, ele.symbol, ele.name, ele.eleconfig) print(ele.eleconfig_dict) print(sum(ele.mass for ele in ELEMENTS)) for ele in ELEMENTS: ele.validate() ele = repr(ele) print(ele, type(ele)) input("next ?")