title: "count no.of 0's" .model small .stack 100h .data num1 db 05h count db dup(0) .code start: mov ax,@data mov ds,ax xor ax,ax mov al,num1 mov cx,08 mov bl,0 again: rol al,1 jc noadd inc bl noadd:loop again mov count,bl mov ah,4ch int 21h end ************************* title: "count no.of 0's" .model small .stack 100h .data num1 db 0feh count db dup(0) .code start: mov ax,@data mov ds,ax xor ax,ax mov al,num1 mov cx,08 mov bl,0 again: rol al,1 jc noadd inc bl noadd:loop again mov count,bl mov ah,4ch int 21h end
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter