package main
import (
"fmt"
"regexp"
)
func main() {
text := "`От:` <@317989885321674753>\n`На:` <@163995016027439106>\n`Причина:` <@!163995016027439106>"
re := regexp.MustCompile(`\<\@\!?(\d{18})\>`)
matches := re.FindAllStringSubmatch(text, -1)
for _, match := range matches {
if len(match) > 1 {
fmt.Println(match[1])
}
}
}