how we can write a program ,whech prints its oun source using NASM oder GCC on Linux und mac os x

that strongly depends on the features you request. You can include your sourcecode with

%include "source.asm"

during compilation time or you try to access the file in runtime via the kernel.

For then first solution, NASM should be perfectly alright. Accessing the file in runtime can be quite tricky, but this could be a good start: Click Here

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.