0
Can we save a c programme in .xyz extension..?help plzz and explain how.
answer please
11 Answers
+ 11
Why would you want to save it as a .xyz?
+ 6
You can also compile code into static .lib's...
+ 6
Are you talking about saving the source code .cpp as .xyz or to compile with output .xyz. The second option is probably impossible, especially in Windows, because Windows uses file extension to decide how to treat a file and what to do with it.
If you mean to save .cpp as .xyz that's possible, in Windows, although still not recommended, you can introduce a new file type .xyz to open, or compile by creating association with an IDE, in Linux I can't really say, I'm not so familiar with how it works.
Hth, cmiiw
+ 3
Both are possible, but you'll probably have problem running your executable file if its extension is .xyz
For that you have to use command line
On linux it is gcc, a line like this work :
gcc my_code.abc -o my_prog.xyz
To execute you then do :
./my_prog.xyz
+ 1
@karl t. can we save as .xyz extension
0
not enough
0
@hatsy it's a interview questions. asked by interviewer
0
In Linux you can get away with doing this. Linux does not use extensions to tell if file is executable, so you could theory use nearly any extension. (Normally executable filesâ have no extension.)
For source files you can use any extension, just call the compiler using the terminal.
This is useful if want to do something like compile a c source file into a c++ project.
The text editor or IDE will not show the Syntax highlighting by default.
It's still not recommended to do this.
0
You can but you will have problem executing it.