Say a class has 30 bytes of data storage (char of 30 bytes, say) and 5 methods for manipulating the data. How much memory would be used if 1000 of these objects were created ? Would it be (1000 * 30) + method code size, or 1000 * (30 + method code size) ?
(That is, is the code in the method duplicated for each created instance of it, or just once and pointers used for the rest ?)