Age 18-55 years (both inclusive) at the time of signing informed consent.
Body Mass Index (BMI) 27.0-34.9 kilograms per square metre (kg/m\^2) (both inclusive) at screening, with overweight due to excess adipose tissue as judged by the investigator.
Considered eligible based on medical history, physical examination, vital signs, electrocardiogram and clinical laboratory tests at screening, as judged by the investigator.
You may not be if
Known or suspected hypersensitivity to study intervention(s) or related products.
Previous randomisation in this study.
History of allergies (with the exception of seasonal allergies) or history of anaphylactic reactions.
Female who is pregnant, breastfeeding, intends to become pregnant, or is of childbearing potential and not using adequate contraception.
Current participation (signed informed consent) in any other interventional clinical study.
Exposure to an investigational medicinal product within 30 days or five half-lives of that product (whichever is longer) before screening.
Any disorder, unwillingness or inability which, in the investigator's opinion, might jeopardise participant safety or compliance with the protocol.
Glycated haemoglobin (HbA1c) greater than or equal to (≥) 6.5 percentage (%) (48 millimoles per mole \[mmol/mol\]) at screening.