How can I disable toggles when 2 toggles checked?

Hi Guys!
My problem is I instantiated some prefab toggles on the screen, and I would like to disable the other toggles when 2 of them are cheked, and then when I uncheck one or both of tghem then enable the other ones again to choose again.
Thank you for your helps!

You can keep track of how many toggles are activated with an integer, int togglesPressed. You will have to keep track of the order they are pressed so that the right ones are turned off, could also you an int clickOrder; when the toggle is off you set it to 0, when you click it you set it to another int currentClick; then you increment it currentClick++, when more than 2 toggles are selected you deselect all except for the last 2 clicked. Their clickOrder amount will be the highest. That is just one way, there are toglle groups to do this for you, but not sure if you can do it with 2 toggles being selected afaik it’s only one.