Why do gases have neither a definite shape nor a definite volume?

Gases do not have a definite shape or volume because their molecules are widely spaced and move freely. This allows them to expand and fill any container they are in, adjusting to both shape and volume.