Create an executable for a program in an interpreted language: Difference between revisions

julia example
(Created Nim solution.)
(julia example)
Line 402:
 
Variations and further details are given in the [https://github.com/stedolan/jq/wiki/FAQq%20FAQ jq FAQ].
 
=={{header|Julia}}==
<syntaxhighlight lang="julia">
using StaticCompiler, StaticTools
 
hello() = println(c"Hello world!") # the c"" hsyntax defines static C type string
compile_executable(hello, (), "./") # can now run this as executable "hello"
</syntaxhighlight>{{out}}
<pre>
$ ./hello
Hello world!
</pre>
 
=={{header|Nim}}==
4,102

edits