登录
首页 » Visual C++ » zoj1094

zoj1094

于 2012-06-10 发布 文件大小:1KB
0 161
下载积分: 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 个回复

  • vc-gis
    vc 开发gis相关系统必备 经典书籍,值得学习(vc development of essential classic books related systems gis)
    2011-04-26 01:24:12下载
    积分:1
  • MFCskin
    这里包括五十几个VC++的皮肤,还有使用方法。(This file includes more than 50 VC++ skins,and the method how to use them。)
    2011-10-08 21:36:34下载
    积分:1
  • osgRecipes-master
    osg cookbook 中的源代码,里面有OSG和CG的结合,OSG和CEGUI的结合,OSG与QT的结合以及PHYSX的结合。(the source code of OSGCOOKBOOK,include integration of OSG and CG,CEGUI,QT and physx)
    2013-09-07 21:30:32下载
    积分:1
  • calculator
    用MFC做计算器,满足MFC初学者的教学(make calculator by MFC)
    2010-09-30 14:06:18下载
    积分:1
  • HookIE01
    上网限制:通过添加应用程序黑白名单,禁止或者允许学生机访问指定的网址。(Internet Restrictions: black list by adding an application to prohibit or allow students to access the specified URL.)
    2013-08-13 13:24:32下载
    积分:1
  • 17501500
    用VC写的界面编程,可实现用图形纹理的设计,()
    2018-02-24 23:36:04下载
    积分:1
  • TXTReadWriteDlg
    实现txt文本的读写,实现平台VS2008,可以实现对txt文本的读写操作,支持unicode!(txt write and read MFC you can do it visual studio 2008)
    2015-08-25 08:07:43下载
    积分:1
  • Student-hostel-management-system
    本系统是本人采用Visual C++为开发工具,数据库采用的是最为普及的小型数据库管理系统Access,能实现宿舍管理中的添加信息、修改信息、删除信息、查询信息等必不可少的功能。(This system is I use Visual C++ development tools, database using the most popular small database management system Access, dormitory management to achieve the Add and modify information, delete information, query information and other essential functions.)
    2013-09-07 09:06:47下载
    积分:1
  • Kvip
    用VC++做的考勤系统,ACCESS数据库操作(VC++ to do with the attendance system, ACCESS database operations)
    2009-05-13 11:26:13下载
    积分:1
  • ControlDevice
    一个启用和禁用设备的例子,该代码展示了禁用和启用USB设备的功能。如果需要禁用软驱和光驱,需要修改相应的参数。(Enable and disable a device example, the code to display the disable and enable USB devices. If you need to disable the floppy drive and optical disk drive, a need to amend the corresponding parameters.)
    2008-04-03 11:52:26下载
    积分:1
  • 696518资源总数
  • 106215会员总数
  • 5今日下载