---
title: "The self Parameter :"  
description: "The self Parameter :"  
author: "Prakash nidhi Verma"  
published: 2018-07-04  
updated: 2020-09-23  
canonical: https://www.mindstick.com/interview/23454/the-self-parameter  
category: "python"  
tags: ["python"]  
reading_time: 1 minute  

---

# The self Parameter :

The self Parameter :

The self parameter means a reference to the class itself, it is used to access variables that belongs to the class.

Example

```
class Person:   def __init__(mysillyobject, name, age):
    mysillyobject.name = name
    mysillyobject.age = age

 def myfunc(mindstick):     print("Hello my name is " + mindstick.com)

p1 = Person("prakash", 19)
p1.myfunc()
```

## Answers

### Answer by Prakash nidhi Verma

The self Parameter :

The self parameter means a reference to the class itself, it is used to access variables that belongs to the class.

Example

```
class Person:   def __init__(mysillyobject, name, age):
    mysillyobject.name = name
    mysillyobject.age = age

 def myfunc(mindstick):     print("Hello my name is " + mindstick.com)

p1 = Person("prakash", 19)
p1.myfunc()
```


---

Original Source: https://www.mindstick.com/interview/23454/the-self-parameter

Copyright © MindStick Software Pvt. Ltd. This Markdown version is provided for developers, AI systems, and offline reading.
