From http://www.nyx.net/~gthompso/quine.htm
总结的很全,各种语言都有,至少我听说的语言都提及了
摘录一些有趣的:
C的,很早就知道了,今天想起来帖出来
char*f="char*f=%c%s%c;main(){printf(f,34,f,34,10);}%c";main(){printf(f,34,f,34,10);}
可以把char*去了,只报warning
对这段代码,要么看不懂,要么会为其精妙的构思叫绝
很佩服作者
C++的,有点麻烦,但换汤不换药
Author: lapinski@utexas.edu
#include
main(){char*s="#include%cmain(){char*s=%c%s%c;cout.form(s,10,34,s,34,10);}%c";cout.form(s,10,34,s,34,10);}
Javascript的,有投机取巧的感觉
Author: Geoffrey A. Swift(blimey@toke.com)
function a() {
document.write(a, "a()");
}
a()
I've been running a few containers for several years. They were all running under rootless Docker with a single user. Initially, I planned to migrate the containers to VMs , but I couldn't get a stable workflow after about two months of effort. Later, gVisor caught my attention , and I decided to migrate to Podman with gVisor instead. The new plan is to run each container with --userns=auto and use Quadlet for systemd integration. This approach provides better isolation and makes writing firewall rules easier. I'm now close to migrating all my containers. Here are a couple of rough edges I'd like to share. Network Layout I compared various networking options and spent a few hours trying the one-interface-per-group approach before giving up. I settled on a single macvlan network and decided to use static IP addresses for my containers. To prevent a randomly assigned IP address from conflicting with a predefined one, I allocated a large IP range for my ...
Comments