CSDN博客

img Fangyizhi

程序员的爱情

发表于2004/10/22 16:23:00  835人阅读

 // TMD.cpp
 // a program written by one of my friends in Microsoft
 // last updated by dell

 #include "boy.h"
 #include "girl.h"

 #define AND &&

 RESULT love(boy, girl)
 {
      if( boy.有房() AND 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.有房() AND boy.有车() )
           {
                boy.Set(Nothing);
                return girl.嫁给(boy);
           }
           else if( boy.赚钱 > 100,000 AND girl.感情 > 8 )
                goto next_year;
           else
                return girl.goto( another_boy);
      }
      return girl.goto( another_boy);
 }

阅读全文
0 0

相关文章推荐

img
取 消
img