Per capita, I would have to say that Israel has way better programmers that China! I've worked with both over many years and Yes, China has some fantastic people but I have seen innovation, true innovation, from Israel more times then I can count. One other thing to consider is China is really more of a fast follower and are really good at it. You want them to match a feature of a competitor, they are 2nd to none!
In my limited experience, I've noticed this too. For example, the high density of Israeli programmers implementing lock-free data structures for low latency stuff, and crypto work - your average engineer would be advised not to dabble there, and you don't want your code monkeys near that.
A lot of the industry is still using tools that don't necessarily allow develoepr productivity to grow with intellectual effort of the developer, and in such scenarios development will eventually shift to where the cheaper labour is. One just has to look at how limited the scope of interviews at FAANG are - where's all the modern software engineering stuff?
As long as writing 'efficient' algorithms in imperative languages remains the primary focus instead of abstractions for higher productivity, these top hackerrank devs will do better due to pure statistical advantage.
From somewhere on the internet (removed language names to avoid flame wars):
"The keynote will be about the two approaches used for software development today. Either as large (LARGE) projects with a lot of organization and lots of people using standard technology (Java, C++), or by a small (SMALL) number of highly competent people using advanced technology.
There are cases where LARGE may be necessary, for example in developing software for cellular (mobile) base stations. But for a lot of cases, the SMALL approach is both cheaper and faster. The LARGE approach will inevitably result in outsourcing software development to countries where labor costs are cheaper, we see already that companies like IBM and Ericsson do a lot of their software development in India and China. If we want to keep a vibrant software development business in the West we need to exploit the SMALL approach and also expand it to areas where the LARGE approach is used today. In other words, we need technologies such as X and highly skilled and competent people to exploit them."