Statement of Cash Flows Questions

One area which I am weak at is the statement of cash flows, so I have a few seemingly basic questions for you all for clarification. If I buy PPE for $100, that would be a decrease in cash flows from Investing Activities. Where does the corresponding increase in PPE go? The balance sheet? And if I sell PPE for $100 with a gain of $50, the increase in cash flows from Investing Activities is the full $100 while the gain of $50 goes to Operating Activities?