Give an example of code for this item—the example shouldbe a piece of real progr
ID: 3613191 • Letter: G
Question
Give an example of code for this item—the example shouldbe a piece of real programming language or pseudo code. Describe insimple terms what you can perform using the code.- Method
- Object
- Encapsulation
- Signal
- Operation
- Data Element
- Data Structure
- List
- Stack
- Queue
- Method
- Object
- Encapsulation
- Signal
- Operation
- Data Element
- Data Structure
- List
- Stack
- Queue
Explanation / Answer
Method - int square(int number); The int is for the return type. square is the name. int number isthe formal parameter. Objects are mainly used in java and C++. They are created fromclasses. Say you had an object such as a car. Car ford = new Car(); ford.color = "Red"; Operation deals with math operation such as z = x + y where theyare all variables. Data Structures are mainly made out structs in C. Data structuresare linked list, queues, stacks, and binary trees. A data element would be something inside that structure. List contains a self referential pointer. struct list{ int data; struct list ptr*; }
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.