   Trick Question
  Please don't kill me for this...I was just wondering if we could print some text like Hello GameDev on screen without using any headers or libraries...I don't know how to design my own print functions???Is it possible to do it in some simpler way?   
  In DOS, sure.  Get a pointer to video memory (0x000B8000) and write away to your heart's content.  No header files or libraries required.Under Windows, no.  To output to a console window, you need to at least call WriteConsole to show _something_ on the screen.  Under GDI, you have to do a lot more work with creating a window and selecting a font.  With DirectDraw, you can at least get a pointer to video memory, but you still have to link to some kind of library.If you're just trying to write text output code, use the console routines to display text to the screen.;  I tired using this long int * ptr=(long int *)0x000B8000;but this caused an error that cannot convert from long to long*;  There is nothing wrong with that single line of code.  Something else is causing the problem.  However, it is usually easier to access video memory in char units rather than "long int".You _are_ using a DOS compiler, right?  Visual Studio cannot generate DOS .EXEs.  If you got something compiled and tried to run it, it would crash because the application is not allowed direct memory access.;  First i tried it in VC but it crashed as you said...Then I tried in Dos based compiler with this codchar * ptr=(char*)0x000B8000;*&ptr="Hello bpoint";But there was no output??;  Try:void writeString(char *addr, char *str){    while (*str != 0)    {   *addr = *str++;   addr += 2;    }}int main(){    char *addr = (char *)0x000B8000;    writeString(addr, "Hello bpoint");}The text mode frame buffer is layed out in memory such that two bytes compromise a single character.  One byte is the character itself, the next byte is the color attribute.  Use google, you should be able to find tons of pages about how it works.Is this 32-bit protected mode, by the way?  If not, 16-bit mode requires a far pointer into B800:0000 instead.   ;  Cool Man!!!It worked..Thanks a alot...and yes it was old crappy 16-bit compiler..I don't use it but for this question I had to use it.   ;  Can't we do that in assembly in windows based compiler??   ;  Whether you do it in assembly or in C, it makes no difference.  Windows does not allow direct access to the hardware from user mode.Even if you coded it in assembly, your application would still crash just like the C version did.;  Alright!! Thanks Again :)   