Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > Re: cymbalic reference?

Reply
Thread Tools

Re: cymbalic reference?

 
 
rh
Guest
Posts: n/a
 
      01-16-2013
On Wed, 16 Jan 2013 16:03:47 +1100
Chris Angelico <> wrote:

> On Wed, Jan 16, 2013 at 3:56 PM, rh <>
> wrote:
> > While I'm at it what magic could I use to print "the-class-I-am-in
> > good" instead of hard-coding "Abc good"? I tried __class_ and
> > self.__class__

>
> Almost there! Try self.__class__.__name__ to get the name as a string.


This works. Maybe not that nice to look at...but works.

>
> ChrisA


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: cymbalic reference? rh Python 0 01-16-2013 09:06 PM
Re: cymbalic reference? Terry Reedy Python 0 01-16-2013 05:23 AM
Re: cymbalic reference? Benjamin Kaplan Python 0 01-16-2013 05:08 AM
Re: cymbalic reference? Chris Angelico Python 0 01-16-2013 05:03 AM
cymbalic reference? rh Python 0 01-16-2013 04:56 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57