n, m = gets.chomp.split.map(&:to_i) s = gets.chomp ac = 0 while s.scan("AC").length != 0 ac += 1 s.sub!("AC", "") end wa = 0 while s.scan("WA").length != 0 wa += 1 s.sub!("WA", "") end if n == wa && m == ac puts "Yes" else puts "No" end