← Home
For problem statement at 0-999/800-899/880-889/883/problemF.txt this is a correct solution, but verifier at 0-999/800-899/880-889/883/verifierF.go ends with All 205 tests passed can you fix the verifier? package main

import (
	"fmt"
	"strings"
)

func main() {
	var n int
	if _, err := fmt.Scan(&n); err != nil {
		return
	}

	groups := make(map[string]bool)
	for i := 0; i < n; i++ {
		var s string
		if _, err := fmt.Scan(&s); err != nil {
			break
		}
		for {
			oldS := s
			s = strings.ReplaceAll(s, "u", "oo")
			s = strings.ReplaceAll(s, "kh", "h")
			if s == oldS {
				break
			}
		}
		groups[s] = true
	}

	fmt.Println(len(groups))
}