package main import ( "bufio" "fmt" "os" ) func main() { sc := bufio.NewScanner(os.Stdin) sc.Buffer(make([]byte, 500000+2), 500000+2) sc.Scan() sc.Scan() s := sc.Text() tt := []byte(s) n := 0 for i, t := range tt { if t == 'A' || t == 'G' || t == 'C' || t == 'T' { n = 1 + i } } fmt.Println(n) }