用来填充,补全字符串长度
<script>
const m = new Map(
[
['apple', '10'],
['strawberry', '5'],
['Banana', '0']
]
);
for (let [key, value] of m) {
console.log(key.padEnd(23, ' - '), value.padStart(8, 'count:0'));
}
</script>