Which is better?

or

James K. Polk

US president

James K. Polk

John F. Kennedy

US president

John F. Kennedy