I recently bought this book online used, it came with no CD. Many of the code examples in this book rely on some file called IO.h that apparently came with the CD. I downloaded this file and I still get many errors. Does anyone have these files, or do I even need them? Can I just learn assembly without even assembling files?
Here is what the program looks like, I cant even assemble it because I dont have IO.h, kind of stupid that this book relies on some header file rather than showing you how to do it without header files though
; Example assembly language program -- adds two numbers
; Author: R. Detmer
; Date: revised 7/97
ExitProcess PROTO NEAR32 stdcall, dwExitCode:DWORD
INCLUDE io.h ; header file for input/output
cr EQU 0dh ; carriage return character
Lf EQU 0ah ; line feed
.STACK 4096 ; reserve 4096-byte stack
.DATA ; reserve storage for data
number1 DWORD ?
number2 DWORD ?
prompt1 BYTE "Enter first number: ", 0
prompt2 BYTE "Enter second number: ", 0
string BYTE 40 DUP (?)
label1 BYTE cr, Lf, "The sum is "
sum BYTE 11 DUP (?)
BYTE cr, Lf, 0
.CODE ; start of main program code
output prompt1 ; prompt for first number
input string, 40 ; read ASCII characters
atod string ; convert to integer
mov number1, eax ; store in memory
output prompt2 ; repeat for second number
input string, 40
mov number2, eax
mov eax, number1 ; first number to EAX
add eax, number2 ; add second number
dtoa sum, eax ; convert to ASCII characters
output label1 ; output label and sum
INVOKE ExitProcess, 0 ; exit with return code 0
PUBLIC _start ; make entry point public