I learned that class fields are stored in the heap, but where are methods stored? In the heap or somewhere else? are they inline?
Class methods are stored together with all code in a dedicated segment of program memory meant specifically for storing code. Each method's code is stored once.