zoukankan      html  css  js  c++  java
  • 201314

    我的爱,已没有将来。2013-01-04

    #!/usr/bin/python
    # author: wenhui, 2013-1-5
    # dscrpt: Let the sorrow stay to pass by, 
    # let the memory continue future.
    
    import datetime
    
    class Life:    
        '''I loved you - Alexander Pushkin
            I loved you; even now I may confess,
            Some embers of my love their fire retain;
            But do not let it cause you more distress,
            I do not want to sadden you again.
            Hopeless and tongue-tied, yet I loved you dearly
            With pangs the jealous and the timid know;
            So tenderly I loved you, so sincerely,
            I pray God grant another love you so.'''
    
        def __init__(self):    
            # a memorable day
            self.tick = 201314
        
        def do(self, begin, end):
            # Someday may u wanna change something &
            # print a 'HELLO, WORLD!' at this moment.
            print("HELLO, WORLD!\t" + str(begin)) 
            # but no matter how hard you try,
            # the time escape from ur life.
            self.tick *= 10000
            while self.tick != 0:
                self.tick -= 1
            # end of while
            # At the end of the moment,
            # whatever u can do is to remember now &
            # print a 'GOODBYE, WORLD!'
            print("GOODBYE, WORLD!\t" + str(end))
            # Maybe, this is life.
            
    # class Life        
    
    _from = datetime.date(2010, 12, 25)
    _pass = datetime.timedelta(days = (366+365))
    _to = _from + _pass
    who = Life()
    who.do(_from, _to)
  • 相关阅读:
    解析三种常见分布式锁的实现
    RabbitMQ基础概念详解
    数据库事务概念
    ECIF与CRM
    MQ(消息队列)学习
    数据粒度的设计
    链表之 头节点与尾指针 区别
    牛客之错题(2016.1.15) && 带头节点与不带头的区别
    数据结构之递归回溯算法
    LeetCode--Single Number
  • 原文地址:https://www.cnblogs.com/icanth/p/2845674.html
Copyright © 2011-2022 走看看