Tkinter
変数を用意する †
self.var = IntVar()
変数を初期化する。 †
self.var.set(3)
ボタンを用意する。 †
r1 = Radiobutton(text="radio1",variable=self.var,value=1)
r2 = Radiobutton(text="radio2",variable=self.var,value=2)
r3 = Radiobutton(text="radio3",variable=self.var,value=3)
get()で値を得る。 †
v=self.var.get()