Sarah is organizing a bookshelf and wants to place her books in such a way that the number of books in each row is a perfect square. If she has 50 books, how many books will be left after organizing them into complete rows of perfect squares? Let's think step by step and output the final answer within \boxed{}.
user