Grace bought a book for $8 and some pencils that cost $.50 each. She spent a total of $18. Write and solve an equation to determine how many pencils she bought. Let p represent the number of pencils she bought.

Brian sold half of his baseball cards. The next day, he bought 10 more. Now he has a total of 50 cards. Write and solve an equation to determine how many baseball cards he had before he sold any. Let b represent the number of baseball cards he had.