Object-oriented programming is model of programming

Assignment Help Basic Computer Science
Reference no: EM132876979

Object-oriented programming is a model of programming that is often used to create programs that are simple, efficient, and easy to maintain. The way that object-oriented programming achieves this is by breaking a complex problem down into smaller, simpler problems. It uses a hierarchical inheritance approach--meaning that the sub classes (or child classes) of a class can access all methods from the parent class.

A class is utilized as a type of blueprint for objects to be created, and is basically a collection of similar objects. For example, a "Computer" might be considered a class, while it's objects might be 3 different computers: a Lenovo, a Dell, and an Acer. We can declare variables in the class, and then define what attributes that the objects in the class "Computer" will share, such as cost, color, and brand. The "state" of an object is considered to be something that describes an object, such as the three attributes we listed above. The "behavior" of an object is considered to be something that the object "does", such as a computer "running".

Within the class, a main method as well as other methods are created which utilize objects, statements, and commands to achieve a desired result. There must be at least one main method in the program so that the system knows where to begin executing the program. I have attached an example of a small program that creates a class of "Computer1" which declares two variables: cost and brand. I then create an object called "myComputer" which utilizes those variables to show the cost and brand of my computer, and to display the result along with a string as the output.

Reference no: EM132876979

Questions Cloud

Engaged in the change process to initiate a new project : What can we do as managers to ensure that employees are engaged in the change process to initiate a new project?
Explain what deadlock : Explain what a deadlock is and how it happens in the operating system.
Which of the two offers yields the lower price : A retailer is considering the purchase of 100 units of a specific item from either of two suppliers. Which of the two offers yields the lower price
Demonstrate understanding of research relevant to the fields : Demonstrate understanding of key theoretical, research, and practice issues relevant to the fields of public health and health education.
Object-oriented programming is model of programming : Object-oriented programming is a model of programming that is often used to create programs that are simple, efficient, and easy to maintain.
What account is credited by Bergquist Company : Purchase-related transaction - Under a perpetual inventory system, what account is credited by Bergquist Company to record the return
Discuss in detail the salary components and fringe benefits : You have to prepare components of the salary and Fringe benefits. Discuss in detail the salary components and fringe benefits which you want to incorporate.
Discuss the differences between the macro and micro policy : What issues are raised by privatization and competition in healthcare services? Discuss the differences between the macro and micro policy making?
What is value chain analysis : What is value chain analysis? Include the following in your answer:

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Is biometric system more secure

Is Biometric System More Secure? Why Poor Cyber Security for Mobile Environments Is Threatening on a Global Level. Is Apple Really Virus Proof?

  Travel journal to points of interest from early middle ages

Travel Journal to Points of Interest from the Early Middle Ages, Romanesque, and Gothic Worlds

  Compare and contrast the three process models

Compare and contrast the three process models: Structured English, Decision Table, and Decision Tree.

  Describe the problems arising from lack of policy

Describe the problems arising from a lack of policy, Pick a specific topic that relates to public policy affecting data management,

  Organizational performance is fifth aspect of the model

Organizational performance is the fifth aspect of the model, reflect on the question, do certain leadership behaviors improve and sustain performance

  Find the antilogarithm of 2.1654 to the nearest hundredth

Critical Thinking Consider the equation y = cx2, where c is a constant and x ≥ 0. What operation could be applied to each side of the equation to obtain a linear function of x?

  What asci codes would represent those characters

If the two-digit number were to be stored in an ASCII (text file as character 4 followed by character 5, what ASCI codes would represent those characters?

  Show relationships between the given entities

In a stockbrokerage firm, clients are served by brokers. Each client is assigned to a broker. A broker can handle up to 20 clients.

  Explain how class (static) variables and methods

Explain how class (static) variables and methods differ from their instance counterparts. Give an example of a class that contains at least one class variable and at least one class method. Explain why using a class variable and method rather than an..

  Controls for information systems within IT infrastructures

Determine appropriate access controls for information systems within IT infrastructures. Examine methods that mitigate risk to IT infrastructure with integrity

  Cyber security tools-configuration management

Cyber security tools are available to organizations requiring integration of its problem management, configuration management, and incident management processes

  Supporting quotes surrounded by quotation marks

Defend your choice of topic (Physical protections for your database). Include at least 3 expert supporting quotes surrounded by quotation marks

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