全部版块 我的主页
论坛 提问 悬赏 求职 新闻 读书 功能一区 悬赏大厅 求助成功区
1942 5
2014-03-13
悬赏 3000 个论坛币 已解决
假设10个数字,那么这10个数字就可以组合成10*9=90对组合,对于每一对这样的组合,我们都让其相除,会得到90个数字。我是希望将这90个结果放在同一行中。用excel公式实现。

最佳答案

zmy0123 查看完整内容

请查看附件,是这样的吗?
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

全部回复
2014-3-13 18:36:00
请查看附件,是这样的吗?
附件: 您需要登录才可以下载或查看附件。没有帐号?我要注册
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2014-3-14 00:07:48
楼主,这是很简单的公式不断重复的过程,你可以自己慢慢输公式,这样效果好点
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2014-3-20 09:58:08
using VBA is easier, not sure if you can use excel directly.

Sub perm2()

    ' data start
    Cells(2, 3).Select
    Set Rng = Range(Selection, Selection.End(xlToRight))
    i0 = 0
    For Each c1 In Rng.Cells
        For Each c2 In Rng.Cells
            If c1.Column < c2.Column Then
                i0 = i0 + 1
                'output results
                Cells(11, 2 + i0) = c2.Value / c1.Value
            End If
        Next c2
    Next c1
   
End Sub
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2014-3-20 17:06:59
jjjj6666 发表于 2014-3-20 09:58
using VBA is easier, not sure if you can use excel directly.

Sub perm2()
不知道怎么使用vba呢?
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

2014-3-20 20:29:30
open you excel with the data (the data, using the current VBA) started from C3, select that sheet with the data.

then hit "alt-f11", it will open an vba window, right click VBAProject (for the excel file you have data) under the Project-VBAProject tab (upper left), then "insert->module", then click "module1", paste the macro there.  You can run the macro using the VBA windows by click run->run sub/userforms" or go back to excel and hit "alt-f8" and select the macro name to run.
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群