班级和arry [英] class and arry

查看:90
本文介绍了班级和arry的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

帮助我!

使用一个类来创建任何大小的矩阵A并给出矩阵Aij(它的孩子),i和j是屏幕上的任何列?


谢谢

help me!
use a class to create the matrix A with any size and give the matrix Aij (its children), with i, and j is any column on the screen?

thanks

推荐答案

我不知道为什么你需要孩子,因为我假设你的矩阵类会构造一个任何维度的数组。


我假设因为这是C ++,你的数组只是一个向量的向量,所以你的方法只能在这个数据结构上运行。


您不应该在C ++中使用本机数组。
I don''t know why you need children since I assume your matrix class would construct an array of any dimensions.

I assume that since this is C++, your array will just be a vector of vectors so your methods would just operate on this data structure.

You should not be using native arrays in C++.


@weaknessforcats



你可以告诉我算法从矩阵A制作矩阵Aij子吗?


谢谢......!
@weaknessforcats



you can show me algorithms to make the matrix Aij children from the matrix A?

thanks...!


你有没有试过自己?因为你知道,我们不会为你做,我们只会帮你自己做这件事。


如果你已经尝试过卡住,请发布代码你有(只有相关部分)并告诉我们问题是什么。


如果你还没有,请尝试按照弱智能给你的提示,看看如何远远超过你。然后,当你遇到困难时,你可以再问这里。


请注意,它是C ++而不是C,对吧?只是确定。


问候,

Nepomuk
Have you tried yourself? Because you know, we won''t do it for you, we''ll only help you do it yourself here.

If you have tried and got stuck, please post the code you have (only relevant parts please) and tell us what the problem(s) is/are.

If you haven''t, try following the tips weaknessforcats gave you and see how far you get with those. Then, when you get stuck, you can ask here again.

Mind you, it is C++ not C, right? Just making sure.

Greetings,
Nepomuk


这篇关于班级和arry的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆