• <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

            五月丁香综合激情六月久久| 国内精品伊人久久久久影院对白| 久久久久久精品成人免费图片| 中文字幕无码免费久久| 久久Av无码精品人妻系列| 国产精品久久自在自线观看| 久久久精品国产Sm最大网站| 少妇内射兰兰久久| 久久狠狠一本精品综合网| 婷婷五月深深久久精品| 日本一区精品久久久久影院| 久久精品国产AV一区二区三区| 中文字幕久久欲求不满| AV无码久久久久不卡蜜桃| 国产成人无码精品久久久免费| 亚洲中文久久精品无码ww16| 久久av免费天堂小草播放| 久久国产热精品波多野结衣AV| 亚洲国产成人久久综合碰| 成人精品一区二区久久久| 青草国产精品久久久久久| 香蕉久久久久久狠狠色| 久久精品无码免费不卡| 久久久91精品国产一区二区三区 | 99久久精品久久久久久清纯| 亚洲综合日韩久久成人AV| 久久夜色精品国产亚洲av| 99热都是精品久久久久久| 精品亚洲综合久久中文字幕| av无码久久久久久不卡网站| 久久久久成人精品无码中文字幕| 狠狠色丁香婷婷久久综合| 久久无码人妻精品一区二区三区| 久久成人精品| 一本综合久久国产二区| 无码乱码观看精品久久| 一本久久综合亚洲鲁鲁五月天| 99久久免费国产精品特黄| 久久天天躁狠狠躁夜夜不卡| 新狼窝色AV性久久久久久| 久久人人爽人人爽人人片AV不|