it keeps showing error and now it shows stupid every single letter in my console when I try to run these code
Please post your raw code in a reply.
Notice how you didn’t save daily_sales_replaced.split(",")
to a variable? So when you iterate through daily_sales_replaced, it references the original string and not only prints each character in daily_sales_replaced, but also splits (or really, just removes) the ~
. Hence your output.