There is a line var text = " Привет мир9! Сегодня 17 августа.";
How to delete the first digit found in this line to make a string like:
" Привет мир! Сегодня 17 августа."
There is a line var text = " Привет мир9! Сегодня 17 августа.";
How to delete the first digit found in this line to make a string like:
" Привет мир! Сегодня 17 августа."
Use replace More details here.
Specifically according to your example:
var text = " Привет мир9! Сегодня 17 августа."; console.log(text.replace(/\d/, '')); Source: https://ru.stackoverflow.com/questions/707200/
All Articles