我有这样的二维数组:
[
["01fe237f804a5eff182dcded115c37d3", 0.0140845],
["026e5f1f7f026bf3c763523206aa44bf", 0.03448275],
["04a1c3c79773bd1ecc0372a991adc815", 0.04617604]
]
我想先创建一个哈希,然后将其转换为JSON,以便结果如下所示:
[{address: "01fe237f804a5eff182dcded115c37d3", value: 0.0140845},
{address: "026e5f1f7f026bf3c763523206aa44bf", value: 0.03448275},
{address: "04a1c3c79773bd1ecc0372a991adc815", value: 0.04617604}]