X-ray is a type of electromagnetic radiation with a wavelength shorter than that of visible light. It is used in medical imaging to visualize internal structures of the body such as bones, tissues, and organs. X-ray imaging works by passing the X-ray radiation through the body and detecting the amount of radiation that passes through. Dense structures such as bones will absorb more radiation than softer tissues, resulting in a contrast image that can be used to diagnose various medical conditions. X-rays are also used in other fields such as airport security, material analysis, and astronomy. However, excessive exposure to X-rays can be harmful and increase the risk of cancer, which is why precautions are taken to limit the amount of radiation that patients and professionals are exposed to during medical imaging.