Your’s is also pretty cool but what about the other expressions, you can give it a shot to make these expressions too.
You see what I mean Cid!!!
These expressions are also much needed, so you can try them aswell.
I really dont see why we need them. Cid has made a smiley for all the expressions you need.
I’m really sorry you feel that way!!!
You really dont get it. we’ve been trying for a loooong time to get new smilies. Now we got them, we dont need to bother Bjarne about them anymore.
Here is your answer in a Simple MASM Program.
If you don’t like what to see just erase it from your brains...
BTW, I too appreciate Bjarne’s work. He’s one of my best pals to hang-out with.
; CREATE AND DELETE A FILE
.MODEL SMALL
Display Macro msg
mov dx,offset msg ;Macro to Display Text
mov ah,09h
int 21h
Endm
.Data
FILE1 DB 25 DUP(?)
FILE2 DB 25 DUP(?)
MSG1 DB 'ENTER FILE TO BE CREATE$'
msg2 db 0dh,0ah,'ENTER FILE TO BE DELETE$'
msg3 db 0dh,0ah,'FILE CREATED SUCCESSFULLY$'
msg4 db 0dh,0ah,'UNABLE TO CREATE, FILE ALREADY EXISTS$'
msg5 db 0dh,0ah,'FILE DELETED SUCCESSFULLY'
msg6 db 0dh,0ah,'FILE DOES NOT EXIST$'
.Code
mov ax,@data ;initializing Data Segment
mov ds,ax
Display msg1
LEA SI,FILE1
MOV AH,01H
INPUT1: INT 21H
CMP AL,0DH
JE EOI1
MOV [SI],AL
INC SI
JMP INPUT1
EOI1: MOV AH,5BH ; CREATE A FILE
MOV CX,00
MOV DX,OFFSET FILE1
INT 21H
JNC SUCC1
Display msg4
JMP NEXT1
SUCC1: DISPLAY MSG3
NEXT1: DISPLAY MSG2
LEA SI,FILE2
mov ah,01h
INPUT2: INT 21H
CMP AL,0DH
JE EOI2
MOV [SI],AL
INC SI
JMP INPUT2
EOI2: MOV AH,41H ; DELETE A FILE
MOV DX,OFFSET FILE2
INT 21H
JNC SUCC2
Display msg6
JMP NEXT2
SUCC2: DISPLAY MSG5
NEXT2: mov ah,4ch
int 21h
End