Wednesday February 8, 2012 @ 00:06:09 GMT+10    ( Weather:  n/a )
Home » Weblog Archives

Info *NOTE* This page is NOT the actual weblog entry. The purpose for this page is to provide extra background information on how this particular entry is constructed, by using custom markups and tags. To read the actual content of this entry, please go to here.

The Raw Structure:

Markup | Tag used: BBCode


今天在[url=http://blog.sina.com.cn/u/4aa17af8010005hz]某人的博客[/url]看到一段有趣的一段code:

[center]难道程序员的爱情 就注定是无趣的 是冷酷的吗?![/center]

[code=lang:csharp|title:程序员的爱情 in C#|highlight]
using Life;
using Life.Love;

namespace love
{
/// <summary>;
/// love 的摘要说明。
/// </summary>;
public class love :Life.Love
{
void love(boy, girl)
{
if(boy.有房() && boy.有车())
{
boy.Set(Nothing);
return girl.嫁给(boy);
}
else if(girl.愿意等())
{
next_year:
for(day=1; day<=365; day++)
{
if(day == 情人节)
{
if(boy.GiveGirl(玫瑰))
girl.感情++;
else
girl.感情--;
}
if(day == girl.生日)
{
if( boy.GiveGirl(玫瑰) )
girl.感情++;
else
girl.感情--;
}
boy.拼命赚钱();
}
年龄++;
girl.感情--;
if(boy.有房() && boy.有车())
{
boy.Set(Nothing);
return girl.嫁给(boy);
}
else if(boy.赚钱 > 100,000 && girl.感情 > 8 )
goto next_year;
else
return girl.goto(another_boy);
}

return girl.goto(another_boy);
}
}
}
[/code]

呵呵,看来程序员的爱情还蛮寂寞的说。。。

ps: 兄弟,有几个地方的syntax错了,还有最好不要用 goto。。。 呵呵 开玩笑的。。。

Live Rendering:

The real-time rendered result...

程序员的爱情 - 6:37 pm
Funny Stuff  -  poster 

今天在某人的博客看到一段有趣的一段code:

难道程序员的爱情 就注定是无趣的 是冷酷的吗?!


程序员的爱情 in C# [ Hide ]
[ Highlight ] [ Text ]
using Life;
using Life.Love;
 
namespace love
{
   /// <summary>;
   /// love 的摘要说明。
   /// </summary>;
   public class love :Life.Love
   {
      void love(boy, girl)
      {
         if(boy.有房() && boy.有车())
         {
            boy.Set(Nothing);
            return girl.嫁给(boy);
         }
         else if(girl.愿意等())
         {
            next_year:
            for(day=1; day<=365; day++)
            {
               if(day == 情人节)
               {
                  if(boy.GiveGirl(玫瑰))
                     girl.感情++;
                  else
                     girl.感情--;
               }
               if(day == girl.生日)
               {
                  if( boy.GiveGirl(玫瑰) )
                     girl.感情++;
                  else
                     girl.感情--;
               }
               boy.拼命赚钱();
            }
            年龄++;
            girl.感情--;
            if(boy.有房() && boy.有车())
            {
               boy.Set(Nothing);
               return girl.嫁给(boy);
            }
            else if(boy.赚钱 > 100,000 && girl.感情 > 8 )
               goto next_year;
            else
               return girl.goto(another_boy);
         }
 
         return girl.goto(another_boy);
      }
   }
}


呵呵,看来程序员的爱情还蛮寂寞的说。。。

ps: 兄弟,有几个地方的syntax错了,还有最好不要用 goto。。。 呵呵 开玩笑的。。。
$ view_blog.php 2009.09.17 18:16:41 $
Lost? | XML/HTML sitemap | Contact
38.107.179.242 , 23 queries , 0.5891s
Gzip enabled , CSS compressed , JS compressed
Copyright © 2005-2011 Darren's Outpost