Solved

Writing a C++ program

Posted on 2007-11-13
3
623 Views
Last Modified: 2008-02-01
Write a class called Dog which keeps track of the dog's name, breed, age, and license fee. The license fee will be a set amount: $12.25, since you only need one copy of this in memory, make it static. Include a method which allows you to set the dog's name, breed and age. Include another method which displays the dog's name, breed, age and license fee. Write code to test your class.
0
Comment
Question by:tamiko10
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 30

Expert Comment

by:Axter
ID: 20277385
What is your question?

FYI:
It's against EE policy to do homework questions.

Try doing the work, and when you get stuck, post a specific question along with your code.
0
 
LVL 20

Accepted Solution

by:
ikework earned 500 total points
ID: 20278075
start to create a class Dog with the attributes (member-variables): "name, breed, age, and license fee" ..
note: "The license fee will be a set amount: $12.25, since you only need one copy of this in memory, make it static"

if you are unsure about static members have a look at this:

http://www.cplusplus.com/doc/tutorial/classes2.html#static


ike
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction This article is the first in a series of articles about the C/C++ Visual Studio Express debugger.  It provides a quick start guide in using the debugger. Part 2 focuses on additional topics in breakpoints.  Lastly, Part 3 focuses on th…
Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

735 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question