<human>: Prince Vijaya and his 700 followers left Supparaka, landed on the island at a site believed to be in the district of Chilaw, near modern-day Mannar, and founded the Kingdom of Tambapanni. It is recorded the Vijaya made his landing on the day of Buddha's death. Vijaya claimed Tambapanni his capital and soon the whole island come under this name. Tambapanni was originally inhabited and governed by Yakkhas, having their capital at Sirisavatthu and their queen Kuveni. According to the Samyutta Commentary, Tambapanni was one hundred leagues in extent.  After landing in Tambapanni Vijaya met Kuveni the queen of the Yakkhas, who was disguised as a beautiful woman but was really a 'yakkini' (devil) named Sesapathi.  At the end of his reign, Vijaya, having trouble choosing a successor, sent a letter to the city of his ancestors, Sinhapura, in order to invite his brother Sumitta to take over the throne. However, Vijaya had died before the letter had reached its destination, so the elected minister of the people Upatissa, the Chief government minister or prime minister and leading chief among the Sinhalese became regent and acted as regent for a year. After his coronation, which was held in the Kingdom of Tambapanni, he left it, building another one, bearing his own name. While he was king, Upatissa established the new capital Upatissa, in which the kingdom was moved to from the Kingdom of Tambapanni. When Vijaya's letter arrived, Sumitta had already succeeded his father as king of his country, and so he sent his son Panduvasdeva to rule Upatissa Nuwara.  Upatissa Nuwara was seven or eight miles further north of the Kingdom of Tambapanni. It was named after the regent king Upatissa, who was the prime minister of Vijaya, and was founded in 505 BC after the death of Vijaya and the end of the Kingdom of Tambapanni. CANNOTANSWER

Answer this question "How were the Sinhalese kingdoms formed?" by extracting the answer from the text above.
<bot>: Tambapanni