[Tutor] OOPS Problem
sudhanshu9252 at gmail.com
Mon Apr 13 22:36:04 CEST 2009
I am reading python since last 15 days ,read some basics of python , Last
night was reading about the OOPS concepts ,but getting some problems , going
to discuss with you people.
MY CODE :
I made a class with the name student that prints simply name of the student
as well as his roll_no also, pasting code here .
student is a class name
problem 1: Why we always use first method as a __init__
problem 2: why we put first argument as a self inside the __init__
if __init__ is a constructor then how it works.
How I can run this code , working on ubuntu : but when write inside the
terminal python filename.py but it shows nothing
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Tutor