Thread: Can someopne recheck me?

  1. #1
    TransparentMember correlcj's Avatar
    Join Date
    Jun 2002
    Posts
    378

    Question Can someopne recheck me?

    Can check me?

    1. write a statement that outputs "deposit" if task equals deposit?

    my answer: cout << deposit<< endl;

    2. declare a statement called task of type Atm whose initial value is deposit?

    my answer: task = deposit

    Am i right or wrong here?
    "Be formless, shapeless, like water... You put water into a cup, it becomes the cup, you put water into a bottle, it becomes the bottle, you put it in a teapot, it becomes the teapot... Now water can flow, or it can crash, be water my friend."
    -Bruce Lee

  2. #2
    Registered User 4point5's Avatar
    Join Date
    Oct 2002
    Posts
    44

    Cool

    cout << "deposit" << endl;
    Don't try so hard. Just let it happen.

  3. #3
    Registered User
    Join Date
    Oct 2001
    Posts
    2,934
    1.
    if (task == deposit) cout << "deposit";

    2.
    Atm task = deposit;

Popular pages Recent additions subscribe to a feed