• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>

            coreBugZJ

            此 blog 已棄。

            SPOJ 1. Life, the Universe, and Everything

            1. Life, the Universe, and Everything

            Your program is to use the brute-force approach in order to find the Answer to Life, the Universe, and Everything. More precisely... rewrite small numbers from input to output. Stop processing input after reading in the number 42. All numbers at input are integers of one or two digits.

            Example

            Input:
            1
            2
            88
            42
            99
            Output:
            1
            2
            88
            
            我的代碼:
            section .bss
                    buf : resb 0x4
                    len : resd 0x1
            section .text
                    global  _start
            _start : 
                    xor eax, eax
                    mov [len], eax
                    mov [buf], al
                    mov [buf+1], al
            LOOP_INPUT :
                    call INPUT
                    cmp al, 0xa
                    jne LOOP_INPUT
                    mov al, [buf]
                    cmp al, '4'
                    jne LOOP_JUDGE_E
                    mov al, [buf+1]
                    cmp al, '2'
                    jne LOOP_JUDGE_E
                    jmp EXIT
            LOOP_JUDGE_E :
                    call OUTPUT
                    jmp _start
            INPUT :
                    mov eax, 0x3
                    mov ebx, 0x0
                    mov ecx, buf
                    add ecx, [len]
                    mov edx, 0x1
                    int 0x80
                    mov eax, [len]
                    inc eax
                    mov [len], eax
                    mov al, [ecx]
                    ret
            OUTPUT :
                    mov eax, 0x4
                    mov ebx, 0x1
                    mov ecx, buf
                    mov edx, [len]
                    int 0x80
                    ret
            EXIT :
                    mov eax, 1
                    xor ebx, ebx
                    int 0x80
             
             

            posted on 2011-03-16 13:24 coreBugZJ 閱讀(1042) 評論(0)  編輯 收藏 引用 所屬分類: Assemble

            久久久亚洲欧洲日产国码aⅴ | 久久91综合国产91久久精品| 久久国产精品无码HDAV| 久久精品aⅴ无码中文字字幕不卡 久久精品aⅴ无码中文字字幕重口 | 中文无码久久精品| 777久久精品一区二区三区无码| 久久精品18| 日产精品久久久一区二区| 亚洲午夜精品久久久久久人妖| 麻豆久久| 国产精品99久久精品爆乳| 少妇人妻88久久中文字幕| 久久AAAA片一区二区| 久久久不卡国产精品一区二区| 久久久中文字幕| 日本精品一区二区久久久| 久久精品一区二区三区中文字幕| 久久精品无码一区二区三区免费| 久久久久久久波多野结衣高潮| 久久精品国产69国产精品亚洲 | 久久精品免费观看| 色妞色综合久久夜夜| 少妇久久久久久被弄到高潮| 精品蜜臀久久久久99网站| 久久久久亚洲AV无码观看| 国产午夜精品久久久久九九| 久久青青草原精品国产| 久久久亚洲AV波多野结衣| 久久夜色精品国产噜噜亚洲a| 久久精品国产精品亚洲艾草网美妙| 国产91色综合久久免费| 久久精品黄AA片一区二区三区| 亚洲愉拍99热成人精品热久久| 欧美日韩精品久久久久| 久久男人中文字幕资源站| 人妻中文久久久久| 久久国产视频网| 欧美日韩久久中文字幕| 亚洲色大成网站www久久九| 香蕉久久av一区二区三区| 久久一日本道色综合久久|