我讨厌慢节奏工作,我喜欢充实生活

  我喜欢有效率的工作,就像我走路一样,要比一般的人要走的快些。我喜欢快节奏生活快节奏工作,因为我本性如此,因为我讨厌做事情慢慢吞吞,细嚼慢咽,我怕我会疯掉。我喜欢充实的自己,充实的过生活,工作,以及充实的享受我自己的人生,因为我怕太空虚的我会闷死。我不喜欢做什么事情苦苦求而没有多大收获,我不喜欢做什么想做的事情,目标却没有进展,半途而费。我喜欢从一而终,不会因什么原因改变原先计划,因为我对自己非常的执着,职场也是一样。我永远相信相信自己的没错,只要自己相信自己。我也相信where there is a will,there is a way.....未来的舞台不知道有多大,多广,我相信我会一直走下去,直到我达到我的目标。未来也会认识形形色色的人,有人物的,有不是人物的。有一笔带过的,有印象深刻的。有讨厌的,也有喜欢的。我都要一一面对。人生真的不应该平平凡凡......
阅读全文 >>

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 2
    评论
好的,以下是一段简单的俄罗斯方块代码: ```python import pygame import random # 游戏区宽度 game_width = 10 game_height = 20 block_size = 30 # 定义颜色 BLACK = (0, 0, 0) RED = (255, 0, 0) GREEN = (0, 255, 0) BLUE = (0, 0, 255) # 定义方块和形状 shapes = [ [[1, 1], [1, 1]], [[0, 2, 0], [2, 2, 2]], [[0, 3, 3], [3, 3, 0]], [[4, 4, 0], [0, 4, 4]], [[5, 0, 0], [5, 5, 5]], [[0, 0, 6], [6, 6, 6]], [[7, 7, 7, 7]] ] class Block: def __init__(self, x, y, shape): self.x = x self.y = y self.shape = shape class Tetris: def __init__(self): self.game_over = False self.blocks = [] self.init_pygame() self.init_blocks() # 初始化 Pygame def init_pygame(self): pygame.init() pygame.display.set_caption("俄罗斯方块") pygame.key.set_repeat(200, 50) self.screen = pygame.display.set_mode((game_width * block_size, game_height * block_size)) # 初始化方块 def init_blocks(self): self.current_block = Block(game_width // 2 - 1, 0, random.choice(shapes)) self.next_block = Block(game_width, 0, random.choice(shapes)) # 绘制方块 def draw_block(self, block): for x in range(len(block.shape)): for y in range(len(block.shape[x])): if block.shape[x][y] != 0: pygame.draw.rect(self.screen, RED, (block.x * block_size + y * block_size, block.y * block_size + x * block_size, block_size, block_size), 0) pygame.draw.rect(self.screen, BLACK, (block.x * block_size + y * block_size, block.y * block_size + x * block_size, block_size, block_size), 1) # 绘制游戏区 def draw(self): self.screen.fill(BLACK) for block in self.blocks: self.draw_block(block) self.draw_block(self.current_block) pygame.display.update() # 判断方块是否和游戏区边界相撞 def is_collision(self, block): if block.x < 0 or block.x >= game_width or block.y >= game_height: return True for x in range(len(block.shape)): for y in range(len(block.shape[x])): if block.shape[x][y] != 0: if block.y + x < 0: continue if self.blocks[block.y + x][block.x + y] != None: return True return False # 处理方块落下 def move_down(self): self.current_block.y += 1 if self.is_collision(self.current_block): self.current_block.y -= 1 self.freeze() # 处理方块冻结 def freeze(self): for x in range(len(self.current_block.shape)): for y in range(len(self.current_block.shape[x])): if self.current_block.shape[x][y] != 0: self.blocks[self.current_block.y + x][self.current_block.x + y] = self.current_block self.current_block = self.next_block self.current_block.x = game_width // 2 - 1 self.current_block.y = 0 if self.is_collision(self.current_block): self.game_over = True else: self.next_block = Block(game_width, 0, random.choice(shapes)) # 处理方块移动 def move(self, direction): x = 0 y = 0 if direction == pygame.K_LEFT: x = -1 elif direction == pygame.K_RIGHT: x = 1 elif direction == pygame.K_DOWN: y = 1 temp_block = Block(self.current_block.x + x, self.current_block.y + y, self.current_block.shape) if not self.is_collision(temp_block): self.current_block.x += x self.current_block.y += y # 处理方块旋转 def rotate(self): shape = self.current_block.shape shape.reverse() for i in range(len(shape)): for j in range(i): shape[i][j], shape[j][i] = shape[j][i], shape[i][j] if self.is_collision(Block(self.current_block.x, self.current_block.y, shape)): shape.reverse() for i in range(len(shape)): for j in range(i): shape[i][j], shape[j][i] = shape[j][i], shape[i][j] else: self.current_block.shape = shape # 运行游戏 def run(self): clock = pygame.time.Clock() self.blocks = [[None for _ in range(game_width)] for _ in range(game_height)] while not self.game_over: pygame.time.wait(100) for event in pygame.event.get(): if event.type == pygame.QUIT: self.game_over = True elif event.type == pygame.KEYDOWN: if event.key == pygame.K_SPACE: self.rotate() else: self.move(event.key) self.move_down() self.draw() clock.tick(10) pygame.quit() if __name__ == '__main__': tetris = Tetris() tetris.run() ``` 笑话是:为什么科学家讨厌钠?因为他们觉得钠特别Na!

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值