RosettaCodeData/Task/Menu/Tcl/menu-2.tcl

32 lines
651 B
Tcl

% puts >[select test {}]<
><
% puts >[select "Which is from the three pigs" {
"fee fie" "huff and puff" "mirror mirror" "tick tock"
}]<
1: fee fie
2: huff and puff
3: mirror mirror
4: tick tock
Which is from the three pigs: 0
1: fee fie
2: huff and puff
3: mirror mirror
4: tick tock
Which is from the three pigs: skdfjhgz
1: fee fie
2: huff and puff
3: mirror mirror
4: tick tock
Which is from the three pigs:
1: fee fie
2: huff and puff
3: mirror mirror
4: tick tock
Which is from the three pigs: 5
1: fee fie
2: huff and puff
3: mirror mirror
4: tick tock
Which is from the three pigs: 2
>huff and puff<