Read the problem statement and input carefully..........@ Each integers in the input is 32 bit signed integer!!!!!!!!!!!!
You have defined MAX only 100009............when executing arraya[p]++ or arrayb[p]++ it occurs array overflow for those cases where the value of p is more than 100009 ...
Search found 4 matches
- Fri Aug 19, 2011 10:34 pm
- Forum: Volume 120 (12000-12099)
- Topic: 12049 - Just Prune The List
- Replies: 14
- Views: 7170
- Mon Aug 16, 2010 4:17 pm
- Forum: Volume 107 (10700-10799)
- Topic: 10793 - The Orc Attack
- Replies: 35
- Views: 24928
WA: 10793 - The Orc Attack............Cant find the reason o
If there is only one rally point in the given map and also itself a farthest point then what will be the correct result.....
suppose for
1
6 5
6 1 1
6 2 1
6 3 1
6 4 1
6 5 1
what will be the output ???and plz give me some sample input output.........
suppose for
1
6 5
6 1 1
6 2 1
6 3 1
6 4 1
6 5 1
what will be the output ???and plz give me some sample input output.........
- Mon Aug 16, 2010 4:06 pm
- Forum: Volume 107 (10700-10799)
- Topic: 10793 - The Orc Attack
- Replies: 35
- Views: 24928
WA: 10793 - The Orc Attack........Plz someone help me
#include<stdio.h>
long A[1100][1100],B[1100][1100],check[1100];
long node;
void init(void)
{
long i,j;
for(i=0;i<node;i++)
{
check =0;
for(j=0;j<node;j++)
{
if(i==j)
{
A [j]=0;
B [j]=0;
}
else
{
A [j]=10000000;
B [j]=10000000;
}
}
}
return;
}
void warshall(void)
{
long k,i,j ...
long A[1100][1100],B[1100][1100],check[1100];
long node;
void init(void)
{
long i,j;
for(i=0;i<node;i++)
{
check =0;
for(j=0;j<node;j++)
{
if(i==j)
{
A [j]=0;
B [j]=0;
}
else
{
A [j]=10000000;
B [j]=10000000;
}
}
}
return;
}
void warshall(void)
{
long k,i,j ...
- Fri Jul 16, 2010 2:28 pm
- Forum: Volume 3 (300-399)
- Topic: 330 - Inventory Maintenance
- Replies: 26
- Views: 10530
Getting WA 330 : someone plz help me.........
#include<stdio.h>
#include<string.h>
#include<stdlib.h>
#define MAX 100010
#define LEN 20
struct List
{
char s[LEN+1];
char t[LEN+1];
}list[MAX];
long M;
char map[10005][100],temp[10000],buf[10000],str[10000];
double mat[10005][10]={0};
int sort_function( const void *a, const void *b ...