View Problem
Fun

produces a copy of its own source code

In computing, a quine is a computer program which produces a copy of its own source code as its only output.
DiskEdit
python
# adapted from a Quine by Sean B. Palmer

print (lambda s='print (lambda s=%r: (s %% s))()': (s % s))()
DiskEdit
python
x='x=%r;print(x%%x)';print(x%x)
DiskEdit
fsharp
(fun s -> printf "%s %s" s s) "(fun s -> printf \"%s %s\" s s)"
DiskEdit
fantom
class Q
{
static Void main()
{
r := "class Q\n{\n static Void main()\n {\n r := "
s := "\n s := \n echo (r+r.toCode+s[0..9]+s.toCode+s[10..-1])\n }\n}"
echo (r+r.toCode+s[0..9]+s.toCode+s[10..-1])
}
}
DiskEdit
fantom
class Q{static Void main(){s:="class Q{static Void main(){s:=;c:=34.toChar;echo(s[0..<30]+c+s+c+s[30..-1]);}}";c:=34.toChar;echo(s[0..<30]+c+s+c+s[30..-1]);}}

Submit a new solution for python, fsharp, or fantom
There are 20 other solutions in additional languages (clojure, cpp, groovy, haskell ...)