degrees of freedom (mechanism)
The degrees of freedom of a mechanism is the number of independent ways it can move — how many separate dials you would have to set before its shape is completely pinned down. Each dial is one motion you can choose freely without affecting the others. A door on a hinge has one degree of freedom: the only thing you can vary is its open angle, so one number fully describes it. A computer mouse sliding on a desk has two: how far left-or-right and how far forward-or-back. The count is simply how many of these free choices the mechanism gives you.
This number tells you, at a glance, how capable and how controllable a robot is. To place an object anywhere on a flat table and also spin it to any angle, you need three degrees of freedom; to put a tool at any point in 3-D space and aim it in any direction, you need six — which is exactly why a typical robot arm has six joints. Roughly, more degrees of freedom means more versatility and the ability to strike awkward poses, but also more motors to buy, more weight to carry, and more numbers a controller must juggle.
There is a neat bookkeeping rule for working it out. In an open chain, each simple joint adds one degree of freedom, so you can almost just count the joints. In a looped, closed chain it is subtler, because every loop ties motions together and quietly cancels some freedom out; engineers use a formula (the Grübler–Kutzbach criterion) to tally the parts and joints and subtract the constraints. If the final count comes out to zero, the thing is a rigid frame that cannot move at all; if it is negative, the design is over-braced and would normally jam (unless special geometry sets it free).
Your own arm, from shoulder to wrist, has about seven degrees of freedom. That extra one beyond the six needed to place your hand is why you can keep your fingertip pressed on a spot while still swinging your elbow around it.
Count the independent motions: that count is the degrees of freedom.
Don't confuse a mechanism's degrees of freedom (how it can move) with a single rigid body's six degrees of freedom in space (three to slide, three to rotate).