Gaming speed, cores and clocks
On our gaming index the Ryzen 7 3700 scores 37.8 and the Core i5-8400 scores 36, about 5% faster for gaming. That gap is small and mostly shows up at 1080p with a very fast graphics card.
The Ryzen 7 3700 has 8 cores and 16 threads, and the Core i5-8400 has 6 cores and 6 threads. The extra cores of the Ryzen 7 3700 help with video editing, streaming while you play and heavy multitasking more than with the game itself. Boost clocks are 4.1 GHz and 4 GHz.