#对角线

输出对角线(输出格式控制)

 #include<stdio.h>intmain(void){inti;intx;/*瑕佹樉绀虹殑琛屾暟*/printf("helloworld");scanf("%d",&x);for(i=1;i<=x;i++)printf("%*d",i,i%10);return0;}输出he...

输出对角线(空格控制)

 #include<stdio.h>intmain(void){inti,j;intx;printf("helloworld");scanf("%d",&x);for(i=1;i<=x;i++){for(j=1;j<i;j++)putchar('');printf("%d",i...

求矩阵的主对角线之和

importjava.io.BufferedReader;importjava.io.IOException;importjava.io.InputStreamReader;importjava.util.Scanner;publicclassTriangle{publicstaticvoidmain(String[]...
代码星球 ·2020-08-30

python控制窗口对角线运动

 importwin32conimportwin32guiimporttimewhileTrue:time.sleep(1)notepad=win32gui.FindWindow("Notepad","无标题-记事本")forsizeinrange(0,1620):time.sleep(0.001)win32...

代码实现:求一个3*3矩阵对角线元素之和

//求一个3*3矩阵对角线元素之和publicclassTest29{publicstaticvoidmain(String[]args){int[][]a=newint[][]{{100,2,3,},{4,5,6},{17,8,9}};matrSum(a);}privatestaticvoidmatrSum(int[...