求解c++非常急需拜託拜託,謝謝
1.寫一程式,先宣告一陣列:int arr[4][6],並以rand()方式產生亂數設定給arr陣列的每個元素。接著將陣列每一列個別排序(由大至小排序)後顯示在螢幕上。(先顯示arr排序前在顯示排序後)。
2.求下列程式執行結果:
char strl[100]="www.ncut.edu.tw";
int mat1[10]={3,5,6,2,0,1,7,9,3,-8};
int mat2[12]={2,4,6,8,3,5,7,9,1,4,7,0};
int c,d,e,*p1,*p2;
char f,*ptrl;
p1=mat1; p2=mat2; ptrl=strl;
printf("(a)=%s",ptrl+2);
printf("(b)=%c",*ptrl);
c=mat1[mat2[4]+3];
d=*p2+6;
e=*(p2+*p1*3);
f=*(ptrl+*(p1+7));
This entry passed through the Full-Text RSS service — if this is your content and you're reading it on someone else's site, please read the FAQ at fivefilters.org/content-only/faq.php#publishers.