Aliqobilov Madiyor 10- amaliy topshiriq variant


Download 15.73 Kb.
Sana05.01.2022
Hajmi15.73 Kb.
#209556
Bog'liq
122 20 xoqon


122-20 “AT va T” guruh talabasi Aliqobilov Madiyor 10- amaliy topshiriq

  1. variant

1-topshiriqlar

int m,n;


Console.Write("Ustunlar sonini kiriting=");

n=Convert.ToInt32(Console.ReadLine());

Console.Write("Satrlar sonini kiriting=");

m=Convert.ToInt32(Console.ReadLine());

int [,] a= new int[m,n];

for(int i=0;i

for(int j=0;j

Console.Write("A["+i+","+j+"]="+i*10+" ");

}

}

___________________________________________________________________________________



2-topshiriqlarim

int m,n,j,p=0;

Console.Write("Satrlar sonini kiriting=");

m=Convert.ToInt32(Console.ReadLine());

Console.Write("Ustunlar sonini kiriting=");

n=Convert.ToInt32(Console.ReadLine());

int [,] a= new int[m,n];

for(int i=0;i

for( j=0;j

Console.Write("A["+i+","+j+"]=");

a[i,j]=Convert.ToInt32(Console.ReadLine());

} }


int k=0;

for( j=0;j

for(int i=0;i

if (a[i,j]%2==1){

k++;

} } }


for (int i=0;i

for( j=0;j

Console.Write("a["+i+","+j+"]="+a[i,j]+" ");

}Console.WriteLine();

}

if(k==m){



Console.Write(p+"- ustunda faqat toq sonlar bor!");

}else Console.Write("Bu "+m+"*"+n+" matritsada faqat toq sonlardan iborat ustun mavjud emas!");



// Ustoz bu misolni javobi chiqmadi lekin o`ylashimcha hammasini to`g`ri qildim !!!
Download 15.73 Kb.

Do'stlaringiz bilan baham:




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling