function convertNumToStr(num) {
return new Intl.NumberFormat("ko-kr").format(num);
}
function convertStrToNum(str) {
var nagative = str.includes("-");
if (!nagative) {
var res = parseInt(str.replaceAll(",", ""));
if (isNaN(res)) {
res = 0;
}
} else {
var res = str.replaceAll("-", "");
res = parseInt(str.replaceAll(",", ""));
if (res > 0) {
res = -1 * res;
}
}
return res;
}