网友您好, 请在下方输入框内输入要搜索的题目:

题目内容 (请给出正确答案)

1、创建一个4位动态显示的IP核,要求支持16进制显示并可有小数点,还支持特殊符号“-”。其模块声明部分如下: module led4(input clk, input (1) disp_data0, input (1) disp_data1, input (1) disp_data2, input (1) disp_data3, (2) reg (3) seg, //段码 (2) reg (4) dig //位码 ); 补充(1)(2)(3)(4)的内容,并分别简述原因。


参考答案和解析
笔记本电脑
更多 “1、创建一个4位动态显示的IP核,要求支持16进制显示并可有小数点,还支持特殊符号“-”。其模块声明部分如下: module led4(input clk, input (1) disp_data0, input (1) disp_data1, input (1) disp_data2, input (1) disp_data3, (2) reg (3) seg, //段码 (2) reg (4) dig //位码 ); 补充(1)(2)(3)(4)的内容,并分别简述原因。” 相关考题
考题 在C盘当前文件夹下有一个已建立好的顺序文件Alph.txt,文件内容为只含有字母的一个字符串(有双引号界定符)。单击窗体,打开Alph.txt文件,读取字符串并显示在文本框Text1中,然后调用StrSort过程将此字符串按ASCII码的顺序重新排列并显示在文本框Text2中,最后将重新排列的字符串存入AlpO.txt文件中(无双引号界定符)。请选择横线处合适的语句( )。Private Sub Form_Load()Dim StrIn As String,StrOut As StringsOpen"C:\Alph.txt"For Input As #1______CloseText1.Text=StrIn______Text2.Text=StrOutOpen"C:\AlpO.txt"For Output As#2______CloseEnd SubPrivate Function StrSort(s As String)As StringDim s Arr() As String *1,i As Integer,j As Integer,n As IntegerDim t As String *1n=Len(s)ReDim sArr(n)For i=1 To ns Arr(i)=Mid(s,i,1)Next iFor i=1 To n-1For j=i+1 To nIf sArr(i)>sArr(j) Thent=sArr(i):sArr(j):sArr(j):sArr(j)=tEnd IfNext j,iFor i=1 To nStrSort=StrSort s Arr(i)Next iEnd FunctionA.Input#1,StrIn StrIn Print#2,StrOutB.Input#1,StrIn StrSort(StrIn) Input#2,StrOutC.Input#2,StrIn StrSort(StrIn) Input#1,StrOutD.Print#1,StrIn StrSort(StrIn) Input#2,StrOut

考题 在窗体上画一个名称为Commandl的命令按钮,然后编写如下事件过程: Private Sub Commandl_Click() x=Input Box("Input") Select Case x Case 1,3 Print"分支1" Case Is>4 Print"分支2" Case Else Print"Else分支" End Select End Sub 程序运行后,如果在输入对话A.分支1B.分支2C.Else分支D.程序出错

考题 下列程序的功能是:将数据1,2,......,8写入顺序文件Num.txt中,请选择正确的程序段 Private Sub Form_Click() Dim i As Integer Open "Num.txt"For Output As #1 For i=1 To 8 ______ Next i Close #1 End SubA.print#1,i B.input#1,i C.print#1 D.input#1

考题 试题一(共20分)阅读下列说明,回答问题1至问题3,将解答填入答题纸的对应栏内。【说明】逻辑覆盖法是设计白盒测试用例的主要方法之一,通过对程序逻辑结构的遍历实现程序的覆盖。针对以下由C语言编写的程序,按要求回答问题。int XOR(char * filename, unsigned long key){FILE* input = NULL,*output = NULL; //1char *outfilename = NULL;int len = strlen(filename);unsigned charbuffer;if( (filename[len-2] == ‘.’) (filename[len-l]== ‘c’)){ //2,3outfilename = new char[len+l]; //4strcpy(outfilename,filename); outfilename[len-2] = ‘\0’;}else{ //5outfilename = new char[len+5];strcpy(outfilename , filename);strncat(outfilename,”.c”,2);}input = fopen(filename,”rb”);if( input = NULL){ //6coutError opening file filenameendl ; //7delete [] outfilename;outfilename = NULL;return 1;}output = fopen(outfilename,”wbf”);if( utput =NULL) { //8coutError creating output file ” outfilename endl; //9delete []outfilename;outfilename =NULL;return 1;}while(! feof(input) ){ //10if( fread(buffer,sizeof(unsigned char), 1,input) != 1 ){ //11if( ! feof(input)){ //12delete [] outfilename; //13outfllename = NULL;fclose(input);fclose(output);return 1;}}else{ //14buffer A= key;fwrite(buffer,sizeof(unsigned char), 1,output);}}fclose(input);fclose(output);delete []outfllename;return 0;}【问题1】(6分)请给出满足100%DC (判定覆盖)所需的逻辑条件。【问题2】(10分)请画出上述程序的控制流图,并计算其控制流图的环路复杂度V(G)。【问题3】(4分)请给出问题2中控制流图的线性无关路径。

考题 在网页中创建一个如下图所示的表单控件的HTML代码是(50)。A.<input type="text" name="T1" size="20">B.<textarea rows="1" name="T1" cols="20"></textarea>C.<input type="radio" value="T1" checked name="R1">D.<select size="1" name="T1"></select>

考题 在网页中创建一个如图8-2所示的表单控件,其相应的HTML代码是(40)。A.<select size=“1”name=“T1”></select>B.<textarea rows=“2”name=“T1”cols=“20”></textarea>C.<input type=“radio”value=“T1”checked name=“R1”>D.<input type=“text”name=“T1”size=“20”>

考题 假定用下面的语句打开文件: Open"Filcl.txt"For Input As#1 则不能正确读文件的语句是( )。A.Input#1,ch$B.Line Input#1,ch$C.ch$一Input$(5,#1)D.Read#1,ch$

考题 使用Do While循环从打开的文件中逐条读取记录。以下能够正确读取数据的程序段是A.Open "c:\File1.txt" For Input As #1 Do While Not EOF() Line Input #1, strLine LoopB.Open "c:\File1.txt" For Input As#1 Do While Not EOF(#1) Line Input #1, strLine LoopC.FileNo=FreeFile Open FileNo For Input As #1 Do While Not EOF(FileNo) Line Input #1, strLine LoopD.FileNo=FreeFile Open FileNo For Input As #1 DoWhile Not EOF(#FileNo) Line Input #1, strLine Loop

考题 假定用下面的语句打开文件:Open“Filel.txt”for Input As#1则不能正确读文件的语句是A.Input#l,ch$B.Line Input#1,ch$C.ch$=Input$(5,#1)D.Read#1,ch$

考题 写异步D触发器的verilog module。(扬智电子笔试) module dff8(clk , reset, d, q); input clk; 写异步D触发器的verilog module。(扬智电子笔试)module dff8(clk , reset, d, q);input clk;input reset;input [7:0] d;output [7:0] q;reg [7:0] q;always @ (posedge clk or posedge reset)if(reset)q = 0;elseq = d;endmodule

考题 【程序说明】 计算下列算式的值。a,Ai为正整数,从键盘输入。其小∑Ai=1+2…+ Ai,Ai!=1 *2*3*Ai(i=1,2… a)。【程序】SET TAIK OFFCLEARINPUT“M=”TO MSTORE 0 TO S1,S2FOR I=1 TO M(8)DO SUB1DO SUB2ENDFOR? ” 所求算式的值为:“+ALLTRIM(STR(S1/S2,15,3))SET TALK ONPROCEDURE SUB1(9)FOR R=1 TO AK=K+RENDFOR(10)RETURNPROCEDURE SUB2(11)FOR P=1 TO AT=T*PENDFOR(12)RETURN(8)A.INPUT“A=”TO AB.INPUT“I=”TO IC.INPUT“R=”TO STR(R)D.INPUT“K=”TOK

考题 在网页中创建一个如下图所示的表单控件的HTML代码是______ 。A.<input type=“text”name=“T1” size=“20”>B.<textarea rows=“1”name=“T1” cols=“20”></textarea>C.<input type=“radio”value=“T1”checked name=“R1”D.<select size=“1”name=“T1”></sclect>

考题 下列程序是整数除法计算的程序,要求在出现异常时,能抛出异常信息。考虑两种异常:(1)输入非数字除数(2)输入除法分母为零该程序运行的三种结果状态如下:(1)输入两个合法整数(2)输入非数字除数(3)输入除数为零请将程序填写完整。注意:不改动程序结构,不得增行或删行。import java.awt.event.*;public class ex3 extends ______implements ActionListener{private JTextField input1,input2, output;private int number1,number2;private double result;public ex3(){______("示范异常");Container c=getContentPane();c.setLayout(new GridLayout(3,2));c.add(new JLabe1("输入分子",SwingConstants.RIGHT));input1=new JTextField(8);c.add(input1);c.add(new JLabe1("输入分母和回车",SwingConstants.RIGHT));input2=new JTextField(8);c.add(input2);input2.addActionListener(this);c.add(new JLabe1(”计算结果”,SwingConstants.RIGHT));output=new JTextField();c.add(output);setSize(400,100);show();}public void actionPerformed(ActionEvent e){DecimalFormat precision3=new DecimalFormat("0.000");output.setText("");//空的JTextField输出try{number1=Integer.parseInt(input1.getText());number2=Integer.parseInt(input2.getText());result=quotient(number1,number2);______;}catch (NumberFormatException nfe){______(this,"你必须输入两个整数","非法数字格式",JOptionPane.ERROR_MESSAGE);}catch (Exception dbz){______(this,"除法异常","除数为零",JOptionPane.ERROR_MESSAGE);}}//定义求商的方法,如遇除数为零时,能抛出异常。public double quotient(int numerator,int denominator)throws Exception{if(denominator= =0)throw new Exception();return(double) numerator/denominator;}public static void main(String args[]){Java3 app=new Java3();app.addWindowListener(new WindowAdapter(){public void windowClosing(WindowEvent e){e.getWindow().dispose();System.exit(0);}});}}

考题 以下事件过程的功能是:从已存在于磁盘上的顺序文件Num1.txt中读取数据,计算读出数据的平方值,将该数据及其平方值存入新的顺序文件Num2.txt中。则在以下横线处合适的语句是( )。A. Input#1,y Print#2,x,yB. Input#2,x Print #1,x,yC. Print#1,x Input#2,x,yD. Input#1,x Print#2,x,y

考题 What is the maximum number of input policy lists that you can attach to an IP interface?() A.1B.2C.128D.512

考题 下列程序的功能是:将数据1,2,…,8写入顺序文件Num.txt中,请选择正确的程序段( )。 Private Sub Form_Click() Dim i As Integer Open "Num.txt" For Output As #1 For i=1 To 8 ______ Next i Close #1 End SubA.print #1,iB.input #1,iC.print #1D.input #1

考题 执行如下程序SET TALK OFFS=0I=1INPUT "N=" TO NDO WHILE S 执行如下程序SET TALK OFFS=0I=1INPUT "N=" TO NDO WHILE SS=S+II=I+1ENDDO?SSET TALK ON如果输入值为5,则最后S的显示值是( )。A.1B.3C.5D.6

考题 x=eval(input()),当用户输入1+2时,x的值为? A.3B.1+2C."1+2"D."3"

考题 某 html 文档中有如下代码,则在浏览器中打开该文档时显示为( )。 form Listl: input type=text name=List1 / br / List2: input type=text name=List 2 / /formA.B.C.D.

考题 在网页中创建一个如图4-5所示的表单控件,其相应的HTML代码是(41)。A.<select size="1" name="T1"></select>B.<textarea rows="2" name="T1" cols="20"></textarea>C.<input type="radio" value="T1" checked name="R1">D.<input type="text" name="T1" size="20">

考题 该商务网站数据库中商品表的部分字段如下:下面是后台修改商品页面的部分表单代码,请根据图和上述字段描述,确定(7)~(9)的表单类型,将答案填写在对应位置。1.<input name="newsbook" type=" (7) " id="nb" value="1"<%if rs1("newsbook")=1 then%>checked<%end if%>>2.<input name="bm" type=" (8) id="bn" size="30" value="<%=rs1("bookname")%>">3.<input type=" (9) " name="go" value="修 改" nClick="return check();">

考题 (24)假定用下面的语句打开文件:Open"File l .txt"For Input As#1则不能正确读文件的语句是A)Input # 1, ch$B)Line Input # 1, ch$C)ch$=Input$(5, # 1)D)Read # 1, ch$

考题 7360 show port(lt:1/1/1)后得到如下反馈Traffic Statistics=============================================================================== Input Output-------------------------------------------------------------------------------Octets 0 0Packets 0 0Errors 0 0 以下说法正确的是:()A、Input代表下行方向流量B、Input代表上行方向流量C、Output代表下行方向流量D、Output代表上行方向流量

考题 What is the maximum number of input policy lists that you can attach to an IP interface?()A、1B、2C、128D、512

考题 Which SQL statement accepts user input for the columns to be displayed, the table name, and the WHERE condition?()A、SELECT 1, "2" FROM 3 WHERE last_name = '4';B、SELECT 1, '2' FROM 3 WHERE 'last_name = '4'';C、SELECT 1, 2 FROM 3 WHERE last_name = '4';D、SELECT 1, '2' FROM EMP WHERE last_name = '4';

考题 单选题1)#include 2)usingnamespacestd; 3)intmain() 4){ 5)inta,b,result; 6)coutab; 8)result=3*a-2*b+1; 9)cout"resultis" A please input two numbers:的前面B please input two numbers:的后面C please input two numbers:的下一行首列D 不确定

考题 单选题1)#include 2)usingnamespacestd; 3)intmain() 4){ 5)inta,b,result; 6)coutab; 8)result=3*a-2*b+1; 9)cout"resultis" A please input two numbers:/nB please input two numbers:C cout”please input two numbers:/n”D ”please input two numbers:/n”

考题 单选题In order to change the direction of rotation of a D-Cmotor () (1) the field leads must be changed (2) the input leads must be changedA (1)onlyB (2)onlyC either(1)or(2)D neither(1)or(2)