background preloader

Structures

Facebook Twitter

Dictionary of Algorithms and Data Structures. Algorithms and Data Structures. Algorithm: a process or set of rules used for calculation or problem-solving, esp. with a computer.Program: a series of coded instructions to control the operation of a computer or other machine. Example Problem: Find the greatest common divisor (GCD) of two integers, m and n.Euclid's Algorithm: while m is greater than zero: If n is greater than m, swap m and n.

Subtract n from m. n is the GCD. Data Structures and Algorithms by John Morris. Patterns and Software: Essential Concepts and Terminology. What Is an Object? (The Java™ Tutorials > Learning the Java Language > Object-Oriented Programming Concepts) Objects are key to understanding object-oriented technology.

What Is an Object? (The Java™ Tutorials > Learning the Java Language > Object-Oriented Programming Concepts)

Look around right now and you'll find many examples of real-world objects: your dog, your desk, your television set, your bicycle. Real-world objects share two characteristics: They all have state and behavior. Dogs have state (name, color, breed, hungry) and behavior (barking, fetching, wagging tail). Bicycles also have state (current gear, current pedal cadence, current speed) and behavior (changing gear, changing pedal cadence, applying brakes). Identifying the state and behavior for real-world objects is a great way to begin thinking in terms of object-oriented programming.