Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #106729

Re: past exam paper help!

From Ian Kelly <ian.g.kelly@gmail.com>
Newsgroups comp.lang.python
Subject Re: past exam paper help!
Date 2016-04-09 08:11 -0600
Message-ID <mailman.117.1460211154.2253.python-list@python.org> (permalink)
References <a543defc-7b29-4eeb-8ab7-6a4f46aeae7c@googlegroups.com> <48c9d6c4-e4e4-4fd2-a962-5d50c5533c92@googlegroups.com> <CALwzidk11gpMCTpT5H4JbZNT_Xfz+Qez1KFqvc4QVhgn2O6=Tw@mail.gmail.com>

Show all headers | View raw


On Sat, Apr 9, 2016 at 7:49 AM, Joseph Caulfield
<josephcaulfield1996@gmail.com> wrote:
> On Saturday, April 9, 2016 at 2:48:16 PM UTC+1, Joseph Caulfield wrote:
>> how would I model a mug  a cylindrical vessel with an open top in python? thansk :)
>
> *as a cylindrical vessel.

class Vessel:

    def __init__(self, shape, open_top=False):
        self.shape = shape
        self.open_top = open_top

mug = Vessel('cylindrical', open_top=True)


If that's not what you meant, then you'll have to be more specific.

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

past exam paper help! Joseph Caulfield <josephcaulfield1996@gmail.com> - 2016-04-09 06:48 -0700
  Re: past exam paper help! Joseph Caulfield <josephcaulfield1996@gmail.com> - 2016-04-09 06:49 -0700
    Re: past exam paper help! Ian Kelly <ian.g.kelly@gmail.com> - 2016-04-09 08:11 -0600
  Re: past exam paper help! Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2016-04-09 15:03 -0400

csiph-web