下列 Python 程序段用于定義判斷回文字符串的自定義函數(shù)。(注:回文字符串是一個正讀和反讀都一樣的字符串,如“12321”或者“noon”等是回文字符串,而“1232”則不是) def pal(s):#判斷回文字符串 st=[“”]*100;top=-1;k=len(s)//2 for i in range(k): top+=1 st[top]=s[i] if len(s)%2==1: (1)______ for i in range(k,len(s)): tmp=st[top] top-=1 if (2)______: return False return True 上述程序段中方框處可選語句為:①k=k+1 ②k=k-1 ③tmp==s[i]④tmp!=s[i] 則程序中(1)、(2)處的語句依次可為( ?。?/h1>
3.有如下程序段: Dim s(1 To 81)As Integer,i As Integer,j As Integer,c As Integer,temp As Integer c=0:s(1)=0 For i=1 To 9 For j=1 To i temp=s(j*i) s(j*i)=j*i If temp<>s(j*i) And s(j*i) Mod 9=0 Then c=c+1 Next j Next i 該程序段運行后,變量 C 的值為( )