---
title: "What are methods and how are they defined?"  
description: "What are methods and how are they defined?"  
author: "Pushpendra Singh"  
published: 2010-10-25  
updated: 2020-09-23  
canonical: https://www.mindstick.com/interview/164/what-are-methods-and-how-are-they-defined  
category: "java"  
tags: ["java"]  
reading_time: 1 minute  

---

# What are methods and how are they defined?

**Methods** are functions that operate on instances of classes in which they are defined. Objects can communicate with each other using methods and can call methods in other classes. Method definition has four parts. They are name of the method, type of object or primitive type the method returns, a list of parameters and the body of the method. A method’s signature is a combination of the first three parts mentioned above.

## Answers

### Answer by Pushpendra Singh

**Methods** are functions that operate on instances of classes in which they are defined. Objects can communicate with each other using methods and can call methods in other classes. Method definition has four parts. They are name of the method, type of object or primitive type the method returns, a list of parameters and the body of the method. A method’s signature is a combination of the first three parts mentioned above.


---

Original Source: https://www.mindstick.com/interview/164/what-are-methods-and-how-are-they-defined

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
