Linux 系统状态的查看及管理工具: pstree ps pgrep&&pkill pidof top htop uptime vmstat iostat pmap glances dstat kill killall nohup screen systemd tmpfiles sleep chk ...
分类:
其他好文 时间:
2018-02-14 16:43:18
阅读次数:
356
You are given coins of different denominations and a total amount of money amount. Write a function to compute the fewest number of coins that you nee ...
分类:
其他好文 时间:
2018-02-12 23:41:52
阅读次数:
345
Phone number in Berland is a sequence of n digits. Often, to make it easier to memorize the number, it is divided into groups of two or three digits. ...
分类:
其他好文 时间:
2018-02-10 14:00:28
阅读次数:
212
Petya is the most responsible worker in the Research Institute. So he was asked to make a very important experiment: to melt the chocolate bar with a ...
分类:
其他好文 时间:
2018-02-09 23:53:07
阅读次数:
244
A Baidu’s engineer needs to analyze and process large amount of data on machines every day. The machines are labeled from 1 to n. On each day, the eng ...
分类:
系统相关 时间:
2018-02-04 00:31:25
阅读次数:
196
Remember the Word Neal is very curious about combinatorial problems, and now here comes a problem about words. Knowing that Ray has a photographic mem ...
分类:
其他好文 时间:
2018-02-03 20:02:30
阅读次数:
166
支付系统的记账业务,需要登记每笔记账流水的账后余额。在大规模并发条件下,简单使用乐观锁或者悲观锁都回严重的锁定数据库,导致性能变慢,下面介绍优化前和优化后的两种处理思路。 第一种方案,使用乐观锁实现过程:Step1:从账户中获取最近余额以及账户当前版本号,代码如下:Select version, b ...
分类:
其他好文 时间:
2018-02-01 23:18:37
阅读次数:
318
1 Quantifiers are used to describe the number or amount of something. Certain quantifiers are used with certain kinds of nouns. a couple of a little a ...
分类:
其他好文 时间:
2018-01-30 17:13:07
阅读次数:
154
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Time : 2018-01-22 22:09 # @Author : hhj# @Site : # @File : def cash_money(amount): while amount>0 amo ...
分类:
编程语言 时间:
2018-01-23 00:49:42
阅读次数:
150
思路:动态规划。对于属于coins的coin,只要知道amount-coin至少需要多少个货币就能表示,那么amount需要的货币数目=amount-coin需要的货币数目+1;如果amount-coin都不能被表示,amount也不能被表示。 方法一:递归,由上至下。 Next challenge ...
分类:
其他好文 时间:
2018-01-22 21:47:02
阅读次数:
266