随笔分类 - Design Pattern
摘要:Error Retries and Exponential Backoff in AWS https://docs.aws.amazon.com/general/latest/gr/api-retries.html Numerous components on a network, such as
阅读全文
摘要:How this game is playe can be found at here. Python ROWS = 6 COLS = 7 def create_board(): return [[' ' for _ in range(COLS)] for _ in range(ROWS)] def
阅读全文
摘要:Design and implement a data structure for a compressed string iterator. It should support the following operations: next and hasNext. The given compre
阅读全文
摘要:Design an in-memory file system to simulate the following functions: ls: Given a path in string format. If it is a file path, return a list that only
阅读全文
摘要:Design a Snake game that is played on a device with screen size = width x height. Play the game online if you are not familiar with the game. The snak
阅读全文
摘要:From:http://bradforj287.blogspot.com/2010/11/efficient-circular-buffer-in-java.html
阅读全文
摘要:Part 1: 前言: 最近看了一些关于短址(short URL)方面的一些博客,有些博客说到一些好的东西,但是,也不是很全,所以,这篇博客算是对其它博客的一个总结吧。 介绍: 短址,顾名思义,就是把长的 URL 转成短的 URL, 现在提供这种服务的有很多公司,我们以google家的 URL sh
阅读全文
摘要:From: https://discuss.leetcode.com/topic/89/write-elevator-program-using-event-driven-programming/9 We can divide into three main components: User Use
阅读全文
摘要:Design a Tic-tac-toe game that is played between two players on a n x n grid. You may assume the following rules: A move is guaranteed to be valid and
阅读全文
摘要:Given an Android 3x3 key lock screen and two integers m and n, where 1 ≤ m ≤ n ≤ 9, count the total number of unlock patterns of the Android lock scre
阅读全文
摘要:Design a simplified version of Twitter where users can post tweets, follow/unfollow another user and is able to see the 10 most recent tweets in the u
阅读全文
摘要:Factory is a design pattern in common usage. Implement a ShapeFactory that can generate correct shape. You can assume that we have only tree different
阅读全文

浙公网安备 33010602011771号