Give a flowchart and a pseudocode for the program.

Assignment Help Programming Languages
Reference no: EM13951125

Design a class named Pet, which should have the following fields:

- Name - The name field holds the name of a pet.

- Type - The type field holds the type of animal that is the pet. Example values are "Dog", "Cat", and "Bird".

- Age - The age field holds the pet's age.

The Pet class should also have the following methods:

- setName - The setName method stores a value in the name field.

- setType - The setType method stores a value in the type field.

- setAge - The setAge method stores a value in the age field.

- getName - The getName method returns the value of the name field.

- getType - The getType method returns the value of the type field.

 - getAge - The getAge method returns the value of the age field.

After designing the class, design a program that creates an object of the class and prompts the user to enter the name, type, and age of his pet. This data should be stored in the object. Use the object's accessor methods to retrieve the pet's name, type, and age and display this data on the screen.

Give a flowchart and a pseudocode for the program.

Reference no: EM13951125

Questions Cloud

Advantages of using voip compared to traditional phones : What are the advantages of using VoIP compared to traditional phones? What are the disadvantages? What switch feature is often used when implementing VoIP?
Reports of walmart bribing mexican officials : In recent years reports of Walmart bribing Mexican officials points to an often encountered problem; working against American regulation. Research the Walmart issue using material from the Economist, the Wall Street Journal or other sources (be su..
Best example of a strong password : Which of the following can be used to determine how much traffic a website is getting?
Determine the effectiveness of a training program : A researcher believes that younger people use more drugs than older ones. He samples 50 teens and 50 people in their thirties measuring the number of times subjects had used marijuana or cocaine in the past three months.
Give a flowchart and a pseudocode for the program. : The type field holds the type of animal that is the pet. Example values are "Dog", "Cat", and "Bird".
Different types of prescreening tests : Complete the following for this assignment: Research different types of prescreening tests, and construct a report for the president of the company.
Explain major differences between a motor and a generator : Explain the major differences between a motor and a generator. Explain in detail how the simple motor works and be sure to include the functions of the reed relay and transistor.
Describe a little about the fsa program : Research the social realists who worked under the FSA program during the Great Depression. Write an essay in your own words that addresses the points below: Describe a little about the FSA program
Design a class named pet, which should have following fields : The type field holds the type of animal that is the pet. Example values are "Dog", "Cat", and "Bird".

Reviews

Write a Review

Programming Languages Questions & Answers

  Write a haskell program to calculates a balanced partition

Write a program in Haskell which calculates a balanced partition of N items where each item has a value between 0 and K such that the difference b/w the sum of the values of first partition,

  Create an application to run in the amazon ec2 service

In this project you will create an application to run in the Amazon EC2 service and you will also create a client that can run on local machine and access your application.

  Explain the process to develop a web page locally

Explain the process to develop a Web page locally

  Write functions

These 14 questions covers java class, Array, link list , generic class.

  Programming assignment

If the user wants to read the input from a file, then the output will also go into a different file . If the user wants to read the input interactively, then the output will go to the screen .

  Write a prolog program using swi proglog

Write a Prolog program using swi proglog

  Create a custom application using eclipse

Create a custom Application Using Eclipse Android Development

  Create a application using the mvc architecture

create a application using the MVC architecture. No scripting elements are allowed in JSP pages.

  Develops bespoke solutions for the rubber industry

Develops bespoke solutions for the rubber industry

  Design a program that models the worms behavior

Design a program that models the worm's behavior.

  Writing a class

Build a class for a type called Fraction

  Design a program that assigns seats on an airplane

Write a program that allows an instructor to keep a grade book and also design and implement a program that assigns seats on an airplane.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd