Soft_Job 板


LINE

code 与 comment 就像是 Jedi 与 Sith 的关系 有兴趣的人可以看看 stackoverflow 上的这个讨论串 http://stackoverflow.com/questions/184618/what-is-the-best-comment-in-source-code-you-have-ever-encountered (短网址: http://tinyurl.com/4qs8x3) 摘录几个我个人觉得颇好笑的 comment: (原本想试着补上中文翻译的,不过翻译非我强项,总觉得翻译得怪怪的 且有些笑点在翻译的过程中就蒸发了 所以…有兴趣的人自己看吧) ================================================== stop(); // Hammertime! ================================================== //When I wrote this, only God and I understood what I was doing //Now, God only knows ================================================== // Magic. Do not touch. ================================================== // drunk, fix later ================================================== /* This is O(scary), but seems quick enough in practice. */ ================================================== This seems to stop morons from messing my code... "Autogenerated, do not edit. All changes will be undone." ================================================== #define TRUE FALSE //Happy debugging suckers ================================================== long long ago; /* in a galaxy far far away */ ================================================== // I don't know why I need this, but it stops the people being upside-down x = -x; ================================================== double penetration; // ouch ================================================== //Dear future me. Please forgive me. //I can't even begin to express how sorry I am. ================================================== // I am not responsible of this code. // They made me write it, against my will. ================================================== // somedev1 - 6/7/02 Adding temporary tracking of Login screen // somedev2 - 5/22/07 Temporary my ass ================================================== options.BatchSize = 300; //Madness? THIS IS SPARTA! ================================================== #Christmas tree initializer toConnect = [] toRead = [ ] toWrite = [ ] primes = [ ] responses = {} remaining = {} ================================================== On initialization of a linked list: last = first; /* Biblical reference */ ================================================== I worked with a guy who was raised a Muslim, but had a rather tongue-in-cheek view of the religion. He left this comment above a particularly nasty chunk of code: // I will give you two of my seventy-two virgins if you can fix this. ================================================== // no comments for you // it was hard to write // so it should be hard to read ================================================== // This comment is self explanatory. -- "Mr. Data, can you show me how to parse this XML?" "Certainly, sir. Let me google that for you." -- StarTrek, the Next Gen. 《Back to 2009》 (误) --



※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 65.87.177.87
1F:推 motocyman:看到圣诞树笑了… 05/17 00:00
2F:推 megaman1206:推圣诞树XD 05/17 00:10
3F:推 james732: 推圣诞树XDDD 我怎麽都没想过要这样写 05/17 00:22
4F:→ andymai:笑是蛮好笑的~但实际上功能都写不完了~哪有闲情逸致搞这些 05/17 00:37
5F:推 tjhuang:大概是圣诞节的晚上,看着万家灯火同时赶code的心酸吧 05/17 00:46
6F:推 loopuntil:很好笑又有点辛酸XD 05/17 01:13
7F:推 dryman:XDDDDDDDDDDD 05/17 07:56
8F:推 tcw026:lol..XD 05/17 08:04
9F:→ tcw026:我喜欢这一个: return 1; # returns 1 05/17 08:59
10F:→ tcw026:推文1: 经典! 但是这一个更好 "i++; // increase i by 1" 05/17 09:00
11F:→ tcw026:推文2: 谁知道他有没有定义#DEFINE 1 成其他的东西.. 05/17 09:02
12F:→ tcw026:推文3:他是用什麽语言? 05/17 09:03
13F:→ tcw026:所以return 1; //加注解 returns 1或许真的有需要XD 05/17 09:05
14F:推 dryman:我最喜欢magic, do not touch 05/17 12:12
15F:推 hilorrk:Now, God only knows....XD 05/17 12:27
16F:推 lwecloud:long long ago, in a galaxy far far away <=这很靠杯XD 05/17 21:04
17F:推 yauhh:我也要学着在工作中导入幽默感 05/18 02:52
18F:推 ledia:我想一切还是以实力的累积优先会比较好 05/19 13:20
19F:推 ctrlbreak:我以前都排火箭 05/19 21:07
20F:推 ikari512:XDDDD 05/19 21:55
21F:→ AmosYang: ↖ XD 05/20 00:14
22F:推 CarlOrz:推 斯巴达 "300; //Madness? THIS IS SPARTA!" !!! 05/22 00:25
23F:推 flylover:XDDDDD 斯巴达跟圣诞树XDD 10/31 02:21







like.gif 您可能会有兴趣的文章
icon.png[问题/行为] 猫晚上进房间会不会有憋尿问题
icon.pngRe: [闲聊] 选了错误的女孩成为魔法少女 XDDDDDDDDDD
icon.png[正妹] 瑞典 一张
icon.png[心得] EMS高领长版毛衣.墨小楼MC1002
icon.png[分享] 丹龙隔热纸GE55+33+22
icon.png[问题] 清洗洗衣机
icon.png[寻物] 窗台下的空间
icon.png[闲聊] 双极の女神1 木魔爵
icon.png[售车] 新竹 1997 march 1297cc 白色 四门
icon.png[讨论] 能从照片感受到摄影者心情吗
icon.png[狂贺] 贺贺贺贺 贺!岛村卯月!总选举NO.1
icon.png[难过] 羡慕白皮肤的女生
icon.png阅读文章
icon.png[黑特]
icon.png[问题] SBK S1安装於安全帽位置
icon.png[分享] 旧woo100绝版开箱!!
icon.pngRe: [无言] 关於小包卫生纸
icon.png[开箱] E5-2683V3 RX480Strix 快睿C1 简单测试
icon.png[心得] 苍の海贼龙 地狱 执行者16PT
icon.png[售车] 1999年Virage iO 1.8EXi
icon.png[心得] 挑战33 LV10 狮子座pt solo
icon.png[闲聊] 手把手教你不被桶之新手主购教学
icon.png[分享] Civic Type R 量产版官方照无预警流出
icon.png[售车] Golf 4 2.0 银色 自排
icon.png[出售] Graco提篮汽座(有底座)2000元诚可议
icon.png[问题] 请问补牙材质掉了还能再补吗?(台中半年内
icon.png[问题] 44th 单曲 生写竟然都给重复的啊啊!
icon.png[心得] 华南红卡/icash 核卡
icon.png[问题] 拔牙矫正这样正常吗
icon.png[赠送] 老莫高业 初业 102年版
icon.png[情报] 三大行动支付 本季掀战火
icon.png[宝宝] 博客来Amos水蜡笔5/1特价五折
icon.pngRe: [心得] 新鲜人一些面试分享
icon.png[心得] 苍の海贼龙 地狱 麒麟25PT
icon.pngRe: [闲聊] (君の名は。雷慎入) 君名二创漫画翻译
icon.pngRe: [闲聊] OGN中场影片:失踪人口局 (英文字幕)
icon.png[问题] 台湾大哥大4G讯号差
icon.png[出售] [全国]全新千寻侘草LED灯, 水草

请输入看板名称,例如:Boy-Girl站内搜寻

TOP