How many swaps do I do in general in bubble sort, compared to selection source?
在冒泡排序中,一般要做多少次交换,对比选择排序呢?
Why don't I just keep track on each pass through the algorithm whether I have done any swaps?
我为什么不仅仅跟踪算法的,每一遍来看看我做了哪些交换呢?
If we had the proper risk management institutions in place, people would have anticipated this risk and would have made swaps or other arrangements to protect themselves against it.
如果我们有合适的风险管理机构,人们能够预料到这种风险,能够提前进行交换或者其他安排,保护自己免受损失。
B It swaps this one and these two, A and B, but it has no access to main's memory.
它交换了这个和这两个变量,A和,但是它没有介入到main的内存中。
You and your partner, Warren Buffett, have for years complained and warned about the dangers ve perceived in the modern derivatives markets, particularly credit derivatives, and also concerns about interest rate swaps, currency swaps, and equity swaps.
你和你的合伙人,沃伦,巴菲特,多年来一直提醒现代衍生品市场中,存在的危险,that,you’,尤其是信用衍生品,利率掉期,货币互换和股票互换。
So in the first case, I didn't have to do any swaps because 1 was the smallest thing.
所以在第一次遍历中,我没有做,任何的交换因为1就是最小的。
All right? Because if I don't do any swaps on a pass through the algorithm, then it says everything's in the right order.
好么?因为如果我,这一遍没有做任何交换,那么就意味着已经排好序了。
How many swaps do I do in selection sort?
那选择排序要做多少次交换呢?
God bless. Oh, sorry, that wasn't a sneeze, it was a two? How many swaps do I do in bubble sort? A lot. Right. Potentially a lot because I'm constantly doing that, that says I'm running that inner loop a whole bunch of times.
上帝保佑,哦,抱歉,我没说清楚,这是两个问题,在冒泡排序中要做多少次排序?许多,正确的,可能要做很多次,因为在持续的干,这就意味着它要做很多次内部循环。
应用推荐