问题 填空题

下面的程序用来删除字符串’AABA’中第1个出现的由DAT单元指定的字符,删除字符后,后面字符前移,并在字符串尾部添加字符,’$’(24H)。请在横线处填充,使程序能达到预定的功能。
DSEG SEGMENT
BUF DB ’AABA’
CNT DW$-BUF
DAT DB 41H
DSEG ENDS
SSEG SEGMENT STACK
DB 256DUP (0)
SSEG ENDS
CSEG SEGMENT
ASSUME DS:DSEG. SS:SSEG,CS:CSEG. ES:DSEG
START PROC FAR
PUSH DS
XORAX,AX
PUSH AX
MOVAX, DSEG
MOVDS,AX
MOVES,AX
CLD
LEADI,BUF
MOVCX,CNT
MOVAL,DAT
REPNE SCASB
JEDEL
JMPEXIT
DEL: JCXZ FILL
NEXT: MOVBL.[DI]
MOV[DI-1],BL
INCDI
LOOP NEXT
FILL: MOV______, 24H
EXIT: RET
START ENDP
CSEG ENDS
ENDSTART

答案

参考答案:BYTE PTR [DI-1]或者byte ptr[di-1]

解析: 该程序先在指定的字符中查找DAT指定的字符41H,若没有查到则该程序结束,若找到,则判断其在字符串中的位置,删除该字符,并将后面的字符前移,根据题目要求在字符串结尾加上字符’$’(24H)。空缺处完成的功能是在字符串结尾加上字符’$’(24H),由于DI的属性是字类型,而操作数要求是字节类型,所以要改变操作数的属性。

单项选择题
单项选择题

Few beyond California’ s technology crowd recognise the name Larry Sonsini; none within its circle could fail to. For four decades he has been lawyer, adviser and friend to many prominent companies and investors. Some consider him the most powerful person in Silicon Valley. Companies beg for his law firm to represent them. The 65-year-old chairman of Wilson Sonsini Goodrich & Rosati (WSG&R) has suddenly been thrust into the spotlight: first, for counselling many of the technology firms now under scrutiny for backdating stock options (and in some cases, serving on their boards); and more recently, as outside counsel to Hewlett-Packard (HP), for initially defending the board’s dubious investigative practices.

WSG&R boasts 600 lawyers and represents around half of Silicon Valley’s public companies, including Apple Sun Microsystems and Google. Last year it ranked first in private-equity and venture-capital deals, with nearly twice as many as its closest rival. Over the past five years WSG&R has worked on over 1 000 mergers and acquisitions, collectively worth over $ 260 billion.

The recent troubles cast a shadow over WSG&R’s reputation. Although Mr. Sonsini is not accused of wrongdoing himself, many of his firm’s clients are on the ropes. Former executives at Brocade Communications suffered criminal charges in July, Mr. Sonsini Served on Brocade’s board until last year and his firm was its outside counsel. He also was on the boards of Pixar, Echelon, Lattice Semiconductor, LSI Logic and Novell all firms at which the issuing of stock options is being called into question.

WSG&R dismisses the idea that Mr. Sonsini faced a conflict of interest by acting as both director and legal adviser to so many firms and says he did not advise HP in its investigation of board members. Mr. Sonsini initially said it was "well done and within legal limits". It now seems it was neither.

The author’s attitude toward Mr. Sonsini’s remarks is ()

A. sceptical

B. indifferent

C. biased

D. sympathetic