https://github.com/kvanttt/freaky-sources
Collection of freaky sources written on C# (mostly quines in different forms).
https://github.com/kvanttt/freaky-sources
palindrome polyglot quine
Last synced: 6 months ago
JSON representation
Collection of freaky sources written on C# (mostly quines in different forms).
- Host: GitHub
- URL: https://github.com/kvanttt/freaky-sources
- Owner: KvanTTT
- License: apache-2.0
- Created: 2013-09-04T21:50:33.000Z (about 12 years ago)
- Default Branch: master
- Last Pushed: 2017-12-10T16:06:31.000Z (almost 8 years ago)
- Last Synced: 2025-04-11T04:02:40.170Z (6 months ago)
- Topics: palindrome, polyglot, quine
- Language: C#
- Homepage:
- Size: 429 KB
- Stars: 12
- Watchers: 3
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Freaky-Sources
==============Collection of freaky sources written on C# (mostly quines in different forms).
More detail description is available on Russian:
* [С днем программиста !! атсиммаргорп менд С (Квайн-палиндром)](https://habrahabr.ru/post/189192/).
* [Звездные войны в исходном коде](http://habrahabr.ru/post/190616/).
* [Интересности из мира квайнов (100 языков, радиационно-устойчивый, часы, змейка)](https://habrahabr.ru/post/232781/).
* [Пишем квайн-полиглот-палиндромы в честь дня 2^2^3](https://habrahabr.ru/company/pt/blog/309702/).## Sources
#### Single Line Comment Palindrome Quine.#### Multi Line Comment Palindrome Quine.
#### Asciimation Quine
Used data from http://asciimation.co.nz/ by Simon Jansen © 1997 - 2011. One compilation per one frame.
#### Quine Clock.
One compilation per one second.
#### Quine Snake.
Use arrow keys to change direction and move snake. Game can be either completed or failed :)
#### Polyglot Quine.
The quine that compilied both in C# and Java.#### Palindrome Polyglot Quine
The quine that compilied both in C# and Java and have a palindromic format (PalindromePolyglotQuine.cs.java):```CSharp
/**///\u000A\u002F\u002A
using System;//\u002A\u002F
class Program{public static void//\u000A\u002F\u002A
Main//\u002A\u002Fmain
(String[]z){String s="`**?`@#_^using System;?_#^class Program{public static void?@#_^Main?_#main^(String[]z){String s=!$!,t=s;int i;int[]a=new int[]{33,94,38,64,35,95,96,63,36};String[]b=new String[]{!&!!,!&n!,!&&!,!&@!,!!,!&_!,!`!,!?!,s};for(i=0;i<9;i++)t=t.?@#_^Replace?_#replace^(!!+(char)a[i],b[i]);t+='*';for(i=872;i>=0;i--)t=t+t?@#_^[i];Console.Write?_#.charAt(i);System.out.printf^(t);}}/",t=s;int i;int[]a=new int[]{33,94,38,64,35,95,96,63,36};String[]b=new String[]{"\"","\n","\\","\\u000A","\\u002F","\\u002A","/","//",s};for(i=0;i<9;i++)t=t.//\u000A\u002F\u002A
Replace//\u002A\u002Freplace
(""+(char)a[i],b[i]);t+='*';for(i=872;i>=0;i--)t=t+t//\u000A\u002F\u002A
[i];Console.Write//\u002A\u002F.charAt(i);System.out.printf
(t);}}/*/}};)t(
ftnirp.tuo.metsyS;)i(tArahc.F200u\A200u\//etirW.elosnoC;]i[
A200u\F200u\A000u\//t+t=t)--i;0=>i;278=i(rof;'*'=+t;)]i[b,]i[a)rahc(+""(
ecalperF200u\A200u\//ecalpeR
A200u\F200u\A000u\//.t=t)++i;9i;278=i(rof;'*'=+t;)]i[b,]i[a)rahc(+!!(^ecalper#_?ecalpeR^_#@?.t=t)++i;9 "Asciimation_1_3.cs"
type "Asciimation_1_3.cs"
goto LOOP:END
```### Powershell:
```powershell
while ($true) {
&"C:\Windows\Microsoft.NET\Framework\v4.0.30319\csc.exe" "Asciimation_1_3.cs"
./"Asciimation_1_3.exe" > "Asciimation_1_3.cs"
type "Asciimation_1_3.cs"
}
```### Linux with mono
```shell
while :
do
mcs "Asciimation_1_3.cs"
mono "Asciimation_1_3.exe" > "Asciimation_1_3.cs"
cat "Asciimation_1_3.cs"
done
```## Tests
Quines, Palidrome, Polyglot and other program tests available in FreakySource.Tests project. Polyglot quine tests require installed Java.
## Licence
* Code for code, data, quine generation under the Apache 2.0 License.
* Generated source codes under the MIT License.Enjoy!
```
___ _____ _____ ^ ^ _ _ ___ _____ ^ _____ __ _
/ _ \ | ___| | ___| | | | | | \ / | / _ \ |_ _| | | | _ | | \| |
/ /_\ \ |___ | | |___ | | | | | \/ | / /_\ \ | | | | | |_| | | |\ |
/_______\ |_____| |_____| |_| |_| |_|\/|_| /_______\ |_| |_| |_____| |_| \_|
_____ _ _ ^ __ _ _____
| _ | | | | | | | | \| | | ___|
| |_| | | |_| | | | | |\ | | __|
|_____ \ |_____| |_| |_| \_| |_____|
\/
```