Pagini recente » Cod sursa (job #2489961) | Cod sursa (job #119780) | Cod sursa (job #109703) | Cod sursa (job #3176909) | Cod sursa (job #231000)
Cod sursa(job #231000)
#include <iostream.h>
#include <fstream.h>
fstream f("tablete.in", ios::in)
fstream g("tablete.out", ios::out)
void main ()
{
int n,k,i,j;
f>>n;
f>>k;
f.get();
for (i=1;i<=n;i++)
{
for (j=1;j<=n;j++)
{
a[i][j]<a[i][j+1];
if (j=k && a[i][j] %2==0)
g<<a[i][j];
}
for (i=1;i<=n;i++)
{
for (j=1;j<=n;j++)
g<<a[i][j];
g<<endl;
}
}
f.close();
g.close();
}