How will you print any character, string or value of a variable without library functions in C?

前端 未结 4 791
攒了一身酷
攒了一身酷 2020-12-29 15:28

If for example I should not use standard library functions like printf(), putchar() then how can I print a character to the screen?

Is there

4条回答
  •  情歌与酒
    2020-12-29 16:20

    Well thank u all for ur answers.I found one simple answer by a comment from Mr. Hao below the question. his answer is simple program like this

    Turbo C(DOS program):

    char far* src = (char far*) 0xB8000000L; 
    *src = 'M'; 
    src += 2; 
    *src = 'D'; 
    

    or try this: http://en.wikipedia.org/wiki/Brainfuck :) – //Hao (an hour ago)

    I tried it on Turbo C and its working. I wanted a simple solution like this and I wanted to accept it as correct answer but he(Hao) gave it as a comment so I pasted it here for other users to know about this on behalf of him and accepted it. Once again thank u Mr.Hao.

提交回复
热议问题