SELECT Name, (SELECT LastName FROM Contacts) FROM Account
Custom Objects
SELECT Name, (SELECT First_Name__c, Last_Name__c FROM Students__r) FROM Class__c