Unless someone has been involved in hiring a recent grad, I don't know how he or she could possibly know the answer to this question. I am starting an academic job in 2 weeks. It's possible that it was considered when my application was reviewed, but I don't think I was asked a single question about my residency program during my interview day. I was of course asked many questions about my time during residency (and fellowship) in terms of the experiences I had, things I liked, things I didn't like, research, etc...
Who knows though?
I would rank as #1 the program that you like the most. If you like two programs equally, then of course rank the more prestigious one higher.