登录
首页 » Visual C++ » zoj1094

zoj1094

于 2012-06-10 发布 文件大小:1KB
0 79
下载积分: 1 下载次数: 4

代码说明:

  zoj094 Matrix multiplication problem is a typical example of dynamical programming. Suppose you have to evaluate an expression like A*B*C*D*E where A,B,C,D and E are matrices. Since matrix multiplication is associative, the order in which multiplications are performed is arbitrary. However, the number of elementary multiplications needed strongly depends on the evaluation order you choose. For example, let A be a 50*10 matrix, B a 10*20 matrix and C a 20*5 matrix. There are two different strategies to compute A*B*C, namely (A*B)*C and A*(B*C). The first one takes 15000 elementary multiplications, but the second one only 3500. Your job is to write a program that determines the number of elementary multiplications needed for a given evaluation strategy. (Matrix multiplication problem is a typical example of dynamical programming. Suppose you have to evaluate an expression like A*B*C*D*E where A,B,C,D and E are matrices. Since matrix multiplication is associative, the order in which multiplications are performed is arbitrary. However, the number of elementary multiplications needed strongly depends on the evaluation order you choose. For example, let A be a 50*10 matrix, B a 10*20 matrix and C a 20*5 matrix. There are two different strategies to compute A*B*C, namely (A*B)*C and A*(B*C). The first one takes 15000 elementary multiplications, but the second one only 3500. Your job is to write a program that determines the number of elementary multiplications needed for a given evaluation strategy. )

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • pack
    C++串口通信代码,接收下位机的数据点,并在前面板画出图形。(数据格式* , , /)内附STM32串口发送数据程序(C++ serial communication code, receive under the data points, and the front panel to draw graphics. (Data format,*, /) containing STM32 serial transmit data program)
    2013-10-28 20:14:38下载
    积分:1
  • serial
    该源码为平时所用的串口调试工具的源码,效果还是挺不错的(The source is usually used for serial debugging tools, source code, the effect is very good)
    2011-07-16 20:45:30下载
    积分:1
  • 截获Windows系统内部的API调用
    截获Windows系统内部的API调用(intercepted within the Windows API calls)
    2004-12-18 15:37:38下载
    积分:1
  • itemhistory
    VC/C++源码,界面编程,记忆菜单,历史记录,mfc70.dll   VC++在子菜单中添加打开文件的历史记录文件,菜单为自动记忆你打开过的文件,方便下次快速打开,示例程序仅以打开TXT格式的文本文件为例,演示如何记录打开的TXT文件记录。(VC/C++ source code, programming interface, memory menu, history, mfc70.dll VC++ added in the sub-menu to open the file history file menu for automatic memory you open the file, allows you to quickly open the sample program is only open TXT format text file, for example, demonstrates how to record TXT file open records )
    2012-11-19 09:52:26下载
    积分:1
  • dllhook
    一个dll劫持的例子,劫持对象是ws2_32.dll(Example of a dll hijack, hijacking object is ws2_32.dll)
    2009-11-07 23:59:22下载
    积分:1
  • Chat
    说明:  这个源代码是在网路上Chatting(用文字)软件的。(this source is the chatting programm using characters in network. )
    2010-03-22 09:32:18下载
    积分:1
  • winapi
    windows API参考手册,使用方便,开发必备的手册,非常难得一本书籍。(Windows API reference manual, easy to use, develop the necessary manual, a rare books very much.)
    2015-02-09 11:03:25下载
    积分:1
  • MapInfo-Tab-to-Shape-File-Tool
    MapInfo的Tab文件转化为ArcGIS的Shape文件(MapInfo Tab files to ArcGIS Shape files)
    2011-10-03 15:35:32下载
    积分:1
  • TomWatch_demo
    这是VC的一个addin的源代码,将其复制到vc下面的addin目录,然后加载后,可以用它来查看调试中的CDC。(This is an addin VC's source code, copies of the following vc addin directory, loaded, can be used to check the CDC debugging.)
    2007-02-05 21:42:42下载
    积分:1
  • 针对Excel格文件操作实现
    在 Visual C++中操作Excel,对开发数据库管理系统很有意义 (read and write excel file,useful for developing database management system)
    2005-05-20 18:59:56下载
    积分:1
  • 696518资源总数
  • 104269会员总数
  • 42今日下载