function func(string, chars) {
return string
.slice(-2)
.split('')
.some(char => chars.includes(char))
}
func('qlw2e3r4!@#$', ['#', '$']) // true
func('qlw2e3r4!@#$00', ['#', '$']) // false
func('0', ['#', '$']) // false
func('00#0', ['#', '$']) // true