Question: Please answer using Python import sys and sys argv Create a program called classname.py. The program should define a class called person that has one

Please answer using Python import sys and sys argv

Create a program called classname.py. The program should define a class called person that has one method called hello, and one attribute called name, which represents the name of the person.

The hello method should print the following string to the screen:

'My name is ____ and I am a _____'

where:

The first blank should be the name attribute

The second blank should be the name of the class

After defining the class, there are three things you must do:

Instantiate an object of the class

Run the hello method of the instantiated object

(e.g., Greg.hello())

For grading purposes, you must also print the name of the class so I can be sure you've created a class

(The expected output is )

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!