Ja Rule dined like a king during his 2-year stint in prison ... telling us he barely touched the crappy cafeteria food -- 'cause he cooked his own grub instead.
J.R. was cruising Midtown in NYC when he admitted the chow hall food at Ray Brook Federal Prison "isn't very good" -- so he barely ate it.
Luckily the 37-year-old claims he and his cellmates were able to cook in their dorm ... and the food was "decent enough." Among the highlights -- cheesecake and lasagna.
Prison cheesecake -- mmmm mmmm.