This has apparently become a taunt by those ill disposed to journalists who have been laid off. It’s pretty useless advice since almost all of them have dipped a toe in these training waters to no avail. Familiarity with code isn’t going to get you a job.
They should try product management and marketing instead. In general both require the ability to listen closely and digest large numbers of inputs, and hit deadlines on quick turnarounds. This is almost as glib as saying learn to code but much more plausible and in the end satisfying for people with those skills. Products are stories, some things are left on the cutting room floor.
The more general problem in finding new work is too many journalists considered themselves a privileged class. New fields might offer all sorts of new rewards but instant status and recognition as a twenty-something isn’t one of them.