0

How would one go about doing this? I tried doing

LDX first,i
LDA bill,x 
STA 'B',i 

but that doesn't work. We've never gone over any problems which assign a character to a variable without inputting it like that.

     BR      main 
first:   .EQUATE 0
last:    .EQUATE 1
age:     .EQUATE 2
bill:    .EQUATE 6
mary:    .EQUATE 10

; * * * * main()
main:    STRO msg1,d         ; cout << "Bill's age? "
     LDX age,i           ; cin >> bill.age
     DECI bill,x

     LDX first,i         ; /// 
     CHARI bill,x
     LDX last,i
     CHARI bill,x
     LDX first,i
     CHARI mary,x
     LDX last,i
     CHARI mary,x        ; ///
Kenneth
  • 19
  • 7

1 Answers1

0

It's not quite clear what you want to do, but maybe this?

LDX first,i
LDA 'B', i
STA bill,x 
Jester
  • 56,577
  • 4
  • 81
  • 125