python測試題
1、下列是雙標簽的是?()
? A:<P>hallo</P>???????
B:<img src=”1.png”>
C:<a href=”www.baidu.com”>
?
2、在網(wǎng)頁中展示為文字標題的是?()
? A:<img src=”1.png”>?????????
B:<h1>再見</h1>
C:<tltle>歡迎</title>
?
3、要使P標簽的文字居中顯示,下列選項正確的是?()
? A:text-align:left;?????????????
B:text-align:center;
C:text-align:right;
?
4、根據(jù)下列代碼判斷,網(wǎng)頁中展示的內(nèi)容類型是?()
? @app.route(‘/’)
? def index():
????? return ‘<h1>HI!flask</h1>’
?
? A:圖片
? B:文字標題
? C:網(wǎng)頁標題
? D:超鏈接
?
5、flask中讀取HTML文件內(nèi)容的功能是?()
? A:render
? B:render_template
? C:template
?
6、要想使下列代碼能夠返回life.html頁面內(nèi)容,空白處應(yīng)該填寫的是?()
? @app.route(‘life’)
? def index():
????? return (?? )
? A:render_template(‘life.html’)
? B:’life.html’?
?
7、HTML頁面中創(chuàng)建模板變量正確的是哪一項?()
? A:<h3>{ t_name }</h3>
? B:<h3>{{ t_name }}</h3>
? C:t_name
? D:<h3> t_name </h3>
?
判斷:
8、input標簽的type屬性設(shè)置為submit可以顯示提交按鈕()
9、POST請求比GET請求更好()
使用data[‘壯猿’]可以在 data = [ ‘約翰’,? ‘瓊斯’,? ‘博士’ ]中提取出“壯猿”()