Scrolling game question?

I am attempting to make a game where my character flies at a vertical angle and has to avoid obstacles to get a higher score. 2 questions. How do I extend the background so that my player doesn't run into a black screen. And how do I make a small object that would display the players score?