The legs of the cockroach have different lengths and functions. The upper portion of the leg is called as coxa, attaches the leg to the thorax.
The trochanter acts like a knee and lets the roach bend its legs.
The femur and tibia resemble thigh and shin bones.
The segmented tarsus acts like an ankle and foot. The hook-like tarsus also helps them to climb walls and walk upside down on ceilings.
Therefore, the correct answer is option C.