About c programs which i am learning in a subject called dsanda means data structures and algorithms.
Wednesday, 11 September 2013
CHECK WEATHER THE GIVEN NUMBER IS PALINDROME OR NOT.
;to check a number is palindrom or not
org 00h
mov r0,#11h
mov a,r0
swap a
cjne a,00h,l1
mov r1,#09h
l1:mov r2,#09h
end;if r1 and r2 are 09h then the number is palindrom if only r2 is 09h then the number is not palindrom
No comments:
Post a Comment