C to python code snippet
C code can be easily translated into Python code. However, the difference in syntax can make this process tedious and time-consuming. Can Vim help you here?
const wc_units_data wc_units_frequency[]=
{
{"mHz", 1e-3},
{"Hz", 1.0},
{"kHz", 1e3},
{"MHz", 1e6},
{"GHz", 1e9},
{NULL,0}
};
def wc_units_frequency():
return {"mHz": 1e-3,
"Hz": 1.0,
"kHz": 1e3,
"MHz": 1e6,
"GHz": 1e9,
"NULL": 0}